moved help text to a seperate function
This commit is contained in:
parent
0dfd595820
commit
e57ad4e2ce
1 changed files with 15 additions and 10 deletions
25
Program.cs
25
Program.cs
|
@ -30,16 +30,8 @@ public static class Program
|
||||||
// Parse cli arguments
|
// Parse cli arguments
|
||||||
if (args.Contains("--help") || args.Contains("-h"))
|
if (args.Contains("--help") || args.Contains("-h"))
|
||||||
{
|
{
|
||||||
Console.WriteLine($"steamguard-cli - v{Assembly.GetExecutingAssembly().GetName().Version}");
|
ShowHelp();
|
||||||
Console.WriteLine();
|
return;
|
||||||
Console.WriteLine("--help, -h Display this help message.");
|
|
||||||
Console.WriteLine("--verbose, -v Display some extra information when the program is running.");
|
|
||||||
Console.WriteLine("--user, -u Specify an account for which to generate a Steam Gaurd code.");
|
|
||||||
Console.WriteLine(" Otherwise, the first account will be selected.");
|
|
||||||
Console.WriteLine("--generate-code Generate a Steam Guard code and exit. (default)");
|
|
||||||
Console.WriteLine("--encrypt Encrypt your maFiles or change your encryption passkey.");
|
|
||||||
Console.WriteLine("--decrypt Remove encryption from your maFiles.");
|
|
||||||
return;
|
|
||||||
}
|
}
|
||||||
Verbose = args.Contains("-v") || args.Contains("--verbose");
|
Verbose = args.Contains("-v") || args.Contains("--verbose");
|
||||||
// Actions
|
// Actions
|
||||||
|
@ -118,6 +110,19 @@ public static class Program
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static void ShowHelp()
|
||||||
|
{
|
||||||
|
Console.WriteLine($"steamguard-cli - v{Assembly.GetExecutingAssembly().GetName().Version}");
|
||||||
|
Console.WriteLine();
|
||||||
|
Console.WriteLine("--help, -h Display this help message.");
|
||||||
|
Console.WriteLine("--verbose, -v Display some extra information when the program is running.");
|
||||||
|
Console.WriteLine("--user, -u Specify an account for which to generate a Steam Gaurd code.");
|
||||||
|
Console.WriteLine(" Otherwise, the first account will be selected.");
|
||||||
|
Console.WriteLine("--generate-code Generate a Steam Guard code and exit. (default)");
|
||||||
|
Console.WriteLine("--encrypt Encrypt your maFiles or change your encryption passkey.");
|
||||||
|
Console.WriteLine("--decrypt Remove encryption from your maFiles.");
|
||||||
|
}
|
||||||
|
|
||||||
static void GenerateCode(string user = "")
|
static void GenerateCode(string user = "")
|
||||||
{
|
{
|
||||||
if (Verbose) Console.WriteLine("Aligning time...");
|
if (Verbose) Console.WriteLine("Aligning time...");
|
||||||
|
|
Loading…
Reference in a new issue