public void UpdateInputConfiguration(InputConfiguration n, InputConfiguration o) { var path = AppConfigProvider.AppConfig.ConfigFolder; var oldConfigPath = Path.Combine(path, o.FileName); var newConfigPath = Path.Combine(path, n.FileName); if (!FileSystemUtils.FileExists(newConfigPath) && FileSystemUtils.FileExists(oldConfigPath)) { FileSystemUtils.MoveFile(oldConfigPath, newConfigPath); } FileSystemUtils.SaveObjectToDisk(n, newConfigPath); }
/*protected void CreateSourceFilesDirectoryIfNotExists(InputScript s) * { * if (!HasSourceFilesDirectory(s)) * CreateSourceFilesDirectory(s); * }*/ protected bool SourceFileExists(InputScript s, string f) { var pathToFile = GetPathToSourceFile(s, f); return(pathToFile != null && FileSystemUtils.FileExists(pathToFile)); }