-
Notifications
You must be signed in to change notification settings - Fork 0
/
Arguments.cs
37 lines (31 loc) · 1003 Bytes
/
Arguments.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
using System.ComponentModel;
using Ookii.CommandLine;
namespace SteamAuth
{
[ParseOptions(
Mode = ParsingMode.LongShort,
CaseSensitive = false,
ArgumentNameTransform = NameTransform.DashCase,
ValueDescriptionTransform = NameTransform.DashCase
)]
[Description("Generates a steam TOTP code using a provided secret.")]
public class Arguments
{
[CommandLineArgument(Position = 0, IsRequired = false)]
[Description("Steam TOTP secret")]
public string? Secret { get; set; }
[CommandLineArgument(IsRequired = false, ShortName = 's')]
[Description("Whether to save the encrypted secret to a config file")]
public bool Save { get; set; }
internal bool IsInvalid { get; private set; }
public Arguments()
{
Secret = null;
Save = false;
}
internal Arguments(bool isInvalid) : this()
{
IsInvalid = isInvalid;
}
}
}