private static void BuildClean(List <string> args, XCom2Edition edition, CancellationToken cancellation) { if (!LocateMod(args, out ModInfo modInfo) || args.Count > 0) { HelpBuild(); return; } var builder = new ModBuilder(modInfo, edition, cancellation); builder.Clean(); }
private static void Build(List <string> args, XCom2Edition edition, CancellationToken cancellation) { if (args.Count > 0 && args[0] == "clean") { args.RemoveAt(0); BuildClean(args, edition, cancellation); return; } var buildType = ModBuildType.Smart; while (args.Count > 0) { if (args[0] == "full") { buildType = ModBuildType.Full; } else if (args[0] == "fast") { buildType = ModBuildType.Fast; } else if (args[0] == "smart") { buildType = ModBuildType.Smart; } else { break; } args.RemoveAt(0); } if (!LocateMod(args, out ModInfo modInfo) || args.Count > 0) { HelpBuild(); return; } var builder = new ModBuilder(modInfo, edition, cancellation); builder.Build(buildType); }