private static async Task Main(string[] args) { var argsProcessor = new ArgsProcessor(args); // For now this is enough. If you run it on macOS you want to sign. if (RuntimeInformation.IsOSPlatform(OSPlatform.OSX)) { MacSignTools.Sign(); return; } // If I want a list of up to date onions run it with '--getonions'. if (argsProcessor.IsGetOnionsMode()) { var api = new BitnodesApi(Console.Out); await api.PrintOnionsAsync(); return; } // If I want a list of up to date onions run it with '--reduceonions'. if (argsProcessor.IsReduceOnionsMode()) { string onionFilePath = Path.Combine(LibraryProjectDirectory, "Tor", "OnionSeeds", "MainOnionSeeds.txt"); var currentOnions = File.ReadAllLines(onionFilePath).ToHashSet(); var api = new BitnodesApi(Console.Out); await api.PrintOnionsAsync(currentOnions); return; } // Only binaries mode is for deterministic builds. OnlyBinaries = argsProcessor.IsOnlyBinariesMode(); IsContinuousDelivery = argsProcessor.IsContinuousDeliveryMode(); ReportStatus(); if (DoPublish || OnlyBinaries) { Publish(); IoHelpers.OpenFolderInFileExplorer(BinDistDirectory); } if (!OnlyBinaries) { if (DoSign) { Sign(); } if (DoRestoreProgramCs) { RestoreProgramCs(); } } }
private static void Main(string[] args) { if (MacSignTools.IsMacSignMode()) { MacSignTools.Sign(); return; } // If I want a list of up to date onions run it with '--getonions'. if (IsGetOnionsMode(args)) { GetOnions(); return; } // If I want a list of up to date onions run it with '--getonions'. if (IsReduceOnionsMode(args)) { ReduceOnions(); return; } // Start with digest creation and return if only digest creation. CreateDigests(); OnlyCreateDigests = IsOnlyCreateDigestsMode(args); if (OnlyCreateDigests) { return; } // Only binaries mode is for deterministic builds. OnlyBinaries = IsOnlyBinariesMode(args); ReportStatus(); if (DoPublish || OnlyBinaries) { Publish(); IoHelpers.OpenFolderInFileExplorer(BinDistDirectory); } if (!OnlyBinaries) { if (DoSign) { Sign(); } if (DoRestoreProgramCs) { RestoreProgramCs(); } } }
private static async Task Main(string[] args) { var argsProcessor = new ArgsProcessor(args); // For now this is enough. If you run it on macOS you want to sign. if (RuntimeInformation.IsOSPlatform(OSPlatform.OSX)) { MacSignTools.Sign(); return; } // Only binaries mode is for deterministic builds. OnlyBinaries = argsProcessor.IsOnlyBinariesMode(); IsContinuousDelivery = argsProcessor.IsContinuousDeliveryMode(); ReportStatus(); if (DoPublish || OnlyBinaries) { Publish(); IoHelpers.OpenFolderInFileExplorer(BinDistDirectory); } if (!OnlyBinaries) { if (DoSign) { Sign(); } if (DoRestoreProgramCs) { RestoreProgramCs(); } } }