wasStitchNET
/Constants.cs |
@@ -9,7 +9,7 @@ |
|
namespace wasStitchNET |
{ |
public struct STITCH_CONSTANTS |
public static class STITCH_CONSTANTS |
{ |
public const string SERVER_IP_PATH = @"ip"; |
public const string UPDATE_PATH = @"update"; |
@@ -34,6 +34,10 @@ |
public const string DATE_TIME_STAMP = @"dd-MM-yyyy HH:mm:ss"; |
public const string LOG_FILE_PATH = @"logs/Stitch.log"; |
|
public const string WORKING_CONFIGURATION_FILE = @"Configuration.xml"; |
public const string DEFAULT_CONFIGURATION_FILE = @"Configuration.xml.default"; |
public const string BACKUP_CONFIGURATION_FILE = @"Configuration.xml.bak"; |
|
public const int LOCAL_FILE_ACCESS_TIMEOUT = 60000; |
} |
} |
/Repository/Stitching/Stitching.cs |
@@ -370,7 +370,7 @@ |
|
// Retrive working file. |
var workingFilePath = string.Join(Path.DirectorySeparatorChar.ToString(), |
path, Constants.WORKING_CONFIGURATION_FILE); |
path, STITCH_CONSTANTS.WORKING_CONFIGURATION_FILE); |
|
StitchProgressUpdate("Parsing working file to be patched."); |
XDocument workingFile; |
@@ -389,7 +389,7 @@ |
try |
{ |
defaultFile = XDocument.Load(string.Join(Path.DirectorySeparatorChar.ToString(), |
path, Constants.DEFAULT_CONFIGURATION_FILE)); |
path, STITCH_CONSTANTS.DEFAULT_CONFIGURATION_FILE)); |
} |
catch (Exception ex) |
{ |
@@ -420,7 +420,7 @@ |
if (!dryrun) |
File.Copy(workingFilePath, |
string.Join(Path.DirectorySeparatorChar.ToString(), |
path, Constants.BACKUP_CONFIGURATION_FILE), true); |
path, STITCH_CONSTANTS.BACKUP_CONFIGURATION_FILE), true); |
} |
catch (Exception ex) |
{ |
@@ -433,7 +433,7 @@ |
{ |
if (!dryrun) |
patchedFile.Save(string.Join(Path.DirectorySeparatorChar.ToString(), |
path, Constants.WORKING_CONFIGURATION_FILE)); |
path, STITCH_CONSTANTS.WORKING_CONFIGURATION_FILE)); |
} |
catch (Exception ex) |
{ |