mirror of
https://github.com/claunia/SabreTools.git
synced 2025-12-16 19:14:27 +00:00
Fix directory ensurance until library fixed
This commit is contained in:
@@ -45,7 +45,7 @@ in -old DAT file. Ignores those entries in -old that are not in -new.";
|
|||||||
string? outdat = GetString(features, OutStringValue);
|
string? outdat = GetString(features, OutStringValue);
|
||||||
|
|
||||||
// Ensure the output directory
|
// Ensure the output directory
|
||||||
outdat = outdat?.Ensure(create: true);
|
outdat = (outdat ?? string.Empty).Ensure(create: true);
|
||||||
|
|
||||||
// Check that all required files exist
|
// Check that all required files exist
|
||||||
if (!File.Exists(olddat))
|
if (!File.Exists(olddat))
|
||||||
|
|||||||
@@ -44,7 +44,7 @@ namespace RombaSharp.Features
|
|||||||
string? outdat = GetString(features, OutStringValue);
|
string? outdat = GetString(features, OutStringValue);
|
||||||
|
|
||||||
// Ensure the output directory
|
// Ensure the output directory
|
||||||
outdat = outdat?.Ensure(create: true);
|
outdat = (outdat ?? string.Empty).Ensure(create: true);
|
||||||
|
|
||||||
// Check that all required directories exist
|
// Check that all required directories exist
|
||||||
if (!Directory.Exists(source))
|
if (!Directory.Exists(source))
|
||||||
|
|||||||
@@ -40,7 +40,7 @@ namespace RombaSharp.Features
|
|||||||
string? newdat = GetString(features, NewStringValue);
|
string? newdat = GetString(features, NewStringValue);
|
||||||
|
|
||||||
// Ensure the output directory
|
// Ensure the output directory
|
||||||
outdat = outdat?.Ensure(create: true);
|
outdat = (outdat ?? string.Empty).Ensure(create: true);
|
||||||
|
|
||||||
// Check that all required files exist
|
// Check that all required files exist
|
||||||
if (!File.Exists(olddat))
|
if (!File.Exists(olddat))
|
||||||
|
|||||||
@@ -171,7 +171,7 @@ namespace SabreTools.DatTools
|
|||||||
reportName = "report";
|
reportName = "report";
|
||||||
|
|
||||||
// Get the proper output directory name
|
// Get the proper output directory name
|
||||||
outDir = outDir?.Ensure();
|
outDir = (outDir ?? string.Empty).Ensure();
|
||||||
|
|
||||||
InternalStopwatch watch = new($"Writing out report data to '{outDir}'");
|
InternalStopwatch watch = new($"Writing out report data to '{outDir}'");
|
||||||
|
|
||||||
|
|||||||
@@ -53,7 +53,7 @@ namespace SabreTools.DatTools
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Ensure the output directory is set and created
|
// Ensure the output directory is set and created
|
||||||
outDir = outDir?.Ensure(create: true);
|
outDir = (outDir ?? string.Empty).Ensure(create: true);
|
||||||
|
|
||||||
InternalStopwatch watch = new($"Writing out internal dat to '{outDir}'");
|
InternalStopwatch watch = new($"Writing out internal dat to '{outDir}'");
|
||||||
|
|
||||||
|
|||||||
@@ -68,7 +68,7 @@ namespace SabreTools.Features
|
|||||||
Parser.ParseInto(internalDat, file);
|
Parser.ParseInto(internalDat, file);
|
||||||
|
|
||||||
// Get the output directory
|
// Get the output directory
|
||||||
OutputDir = OutputDir?.Ensure();
|
OutputDir = (OutputDir ?? string.Empty).Ensure();
|
||||||
OutputDir = file.GetOutputPath(OutputDir, GetBoolean(features, InplaceValue));
|
OutputDir = file.GetOutputPath(OutputDir, GetBoolean(features, InplaceValue));
|
||||||
|
|
||||||
// Extension splitting
|
// Extension splitting
|
||||||
|
|||||||
@@ -149,7 +149,7 @@ namespace SabreTools.Features
|
|||||||
List<ParentablePath> basePaths = PathTool.GetFilesOnly(GetList(features, BaseDatListValue));
|
List<ParentablePath> basePaths = PathTool.GetFilesOnly(GetList(features, BaseDatListValue));
|
||||||
|
|
||||||
// Ensure the output directory
|
// Ensure the output directory
|
||||||
OutputDir = OutputDir?.Ensure();
|
OutputDir = (OutputDir ?? string.Empty).Ensure();
|
||||||
|
|
||||||
// If we're in standard update mode, run through all of the inputs
|
// If we're in standard update mode, run through all of the inputs
|
||||||
if (updateMode == UpdateMode.None)
|
if (updateMode == UpdateMode.None)
|
||||||
|
|||||||
Reference in New Issue
Block a user