Validation Project v2 #471

Merged
GreemDev merged 59 commits from validation-v2 into master 2024-12-31 02:31:28 +00:00
2 changed files with 14 additions and 5 deletions
Showing only changes of commit f976c3c362 - Show all commits

View File

@ -11,6 +11,8 @@ namespace Ryujinx.BuildValidationTasks
{
public static bool Execute(string projectPath)
{
Console.WriteLine("Running Locale Validation Task...");
string path = projectPath + "src/Ryujinx/Assets/locales.json";
string data;
@ -91,6 +93,8 @@ namespace Ryujinx.BuildValidationTasks
sw.Write(jsonString);
}
Console.WriteLine("Finished Locale Validation Task!");
return true;
}

View File

@ -19,16 +19,21 @@ namespace Ryujinx.BuildValidationTasks
else
throw new ArgumentException("Error: too many arguments!");
}
if (string.IsNullOrEmpty(args[0]))
string path = args[0];
if (string.IsNullOrEmpty(path))
throw new ArgumentException("Error: path is null or empty!");
if (!Path.Exists(args[0]))
throw new ArgumentException($"path {{{args[0]}}} does not exist!");
throw new ArgumentException($"path {{{path}}} does not exist!");
if (!Directory.GetDirectories(Path.GetFullPath(args[0])).Contains($"{Path.GetFullPath(args[0])}src"))
throw new ArgumentException($"path {{{args[0]}}} is not a valid ryujinx project!");
path = Path.GetFullPath(path);
LocalesValidationTask.Execute(Path.GetFullPath(args[0]));
if (!Directory.GetDirectories(path).Contains($"{path}src"))
throw new ArgumentException($"path {{{path}}} is not a valid ryujinx project!");
LocalesValidationTask.Execute(path);
}
}
}