Thursday, March 26, 2009
Samuel Kenneth Finzer Update 55
God is good.
Thursday, March 19, 2009
Samuel Kenneth Finzer Update 54
It has been a busy week with the right recliner on the couch breaking, the refrigerator breaking, and going to the Men of Valor conference. The refrigerator is fixed now and the recliner is in the process of being fixed.
Praise God we now have an oxygen tank refilling system. Leyla is able to use the oxygen tanks to go out more without fear of running out of oxygen.
Samuel has a really wonderful dimple. I hope to post some more pictures soon.
Thanks everyone for the prayers, meals, and continued help.
Monday, March 9, 2009
Deleting .svn Folders for Subversion Using C#
Here is how to use it:
DeleteSubFolders(@"c:\svn\MyProject\Trunk",".svn",true);
Here is the code:
public static void DeleteSubFolders(string folderPath, string wildcardPattern, bool top)
{String[] list;
//If we are at the top level, get all directory names that match the pattern
if (top)list = Directory.GetDirectories(folderPath, wildcardPattern, SearchOption.AllDirectories);
else //Get directories and files for matching sub directorieslist = Directory.GetFileSystemEntries(folderPath, wildcardPattern);
foreach (string item in list)
{//Sub directories
if (Directory.Exists(item)){
//Match all sub directoriesDeleteSubFolders(item, "*", false);
}else // Files in directory
{//Get the attribute for the file
FileAttributes fileAtts = File.GetAttributes(item);//If it is read only make it writable
if ((fileAtts & FileAttributes.ReadOnly) != 0)
{File.SetAttributes(item, fileAtts & ~FileAttributes.ReadOnly);
}File.Delete(item);
}
}//Delete the matching folder that we are in
if (top == false)
{Directory.Delete(folderPath);
}}