Compare commits
26 Commits
5ad57465d8
...
7749d8df4e
Author | SHA1 | Date |
---|---|---|
Tim Van Baak | 7749d8df4e | |
Tim Van Baak | 53e208ec31 | |
Tim Van Baak | ce25329d27 | |
Tim Van Baak | 4df5ef84dc | |
Tim Van Baak | 7400334a3d | |
Tim Van Baak | b2ff8896b2 | |
Tim Van Baak | c9bd8c8194 | |
Tim Van Baak | 5989970c42 | |
Tim Van Baak | cc2c29980a | |
Tim Van Baak | 984676f587 | |
Tim Van Baak | fd8c725286 | |
Tim Van Baak | 0dec1e1eec | |
Tim Van Baak | 27ffaccd20 | |
Tim Van Baak | b17ce9485a | |
Tim Van Baak | 3242186208 | |
Tim Van Baak | 11dfa403e4 | |
Tim Van Baak | ae77c3c708 | |
Tim Van Baak | f5afb4105b | |
Tim Van Baak | 7d4f7760be | |
Tim Van Baak | 5dfe9a5bb5 | |
Tim Van Baak | 5472dda931 | |
Tim Van Baak | 9696919773 | |
Tim Van Baak | 3d48a7d6f6 | |
Tim Van Baak | d7c07d1ff1 | |
Tim Van Baak | dab37c239b | |
Tim Van Baak | 135997a7cd |
|
@ -0,0 +1,15 @@
|
||||||
|
using CommandLine;
|
||||||
|
|
||||||
|
namespace MultiversalDiplomacy.CommandLine;
|
||||||
|
|
||||||
|
[Verb("adjudicate", HelpText = "Adjudicate a Multiversal Diplomacy game state.")]
|
||||||
|
public class AdjudicateOptions
|
||||||
|
{
|
||||||
|
[Value(0, HelpText = "Input file describing the game state to adjudicate, or - to read from stdin.")]
|
||||||
|
public string? InputFile { get; set; }
|
||||||
|
|
||||||
|
public static void Execute(AdjudicateOptions args)
|
||||||
|
{
|
||||||
|
throw new NotImplementedException();
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,15 @@
|
||||||
|
using CommandLine;
|
||||||
|
|
||||||
|
namespace MultiversalDiplomacy.CommandLine;
|
||||||
|
|
||||||
|
[Verb("image", HelpText = "Generate an image of a game state.")]
|
||||||
|
public class ImageOptions
|
||||||
|
{
|
||||||
|
[Value(0, HelpText = "Input file describing the game state to visualize, or - to read from stdin.")]
|
||||||
|
public string? InputFile { get; set; }
|
||||||
|
|
||||||
|
public static void Execute(ImageOptions args)
|
||||||
|
{
|
||||||
|
throw new NotImplementedException();
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,18 @@
|
||||||
|
using CommandLine;
|
||||||
|
|
||||||
|
namespace MultiversalDiplomacy.CommandLine;
|
||||||
|
|
||||||
|
[Verb("repl", HelpText = "Begin an interactive 5dplomacy session.")]
|
||||||
|
public class ReplOptions
|
||||||
|
{
|
||||||
|
[Option('i', "input", HelpText = "Begin the repl session by executing the commands in this file.")]
|
||||||
|
public string? InputFile { get; set; }
|
||||||
|
|
||||||
|
[Option('o', "output", HelpText = "Echo the repl session to this file. Specify a directory to autogenerate a filename.")]
|
||||||
|
public string? OutputFile { get; set; }
|
||||||
|
|
||||||
|
public static void Execute(ReplOptions args)
|
||||||
|
{
|
||||||
|
throw new NotImplementedException();
|
||||||
|
}
|
||||||
|
}
|
|
@ -7,6 +7,10 @@
|
||||||
<Nullable>enable</Nullable>
|
<Nullable>enable</Nullable>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
|
<ItemGroup>
|
||||||
|
<PackageReference Include="CommandLineParser" Version="2.9.1" />
|
||||||
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<AssemblyAttribute Include="System.Runtime.CompilerServices.InternalsVisibleTo">
|
<AssemblyAttribute Include="System.Runtime.CompilerServices.InternalsVisibleTo">
|
||||||
<_Parameter1>MultiversalDiplomacyTests</_Parameter1>
|
<_Parameter1>MultiversalDiplomacyTests</_Parameter1>
|
||||||
|
|
|
@ -1,12 +1,23 @@
|
||||||
using System;
|
using CommandLine;
|
||||||
|
|
||||||
namespace MultiversalDiplomacy
|
using MultiversalDiplomacy.CommandLine;
|
||||||
|
|
||||||
|
namespace MultiversalDiplomacy;
|
||||||
|
|
||||||
|
internal class Program
|
||||||
{
|
{
|
||||||
internal class Program
|
|
||||||
{
|
|
||||||
static void Main(string[] args)
|
static void Main(string[] args)
|
||||||
{
|
{
|
||||||
Console.WriteLine("stab");
|
var parser = Parser.Default;
|
||||||
}
|
var parseResult = parser.ParseArguments(
|
||||||
|
args,
|
||||||
|
typeof(AdjudicateOptions),
|
||||||
|
typeof(ImageOptions),
|
||||||
|
typeof(ReplOptions));
|
||||||
|
|
||||||
|
parseResult
|
||||||
|
.WithParsed<AdjudicateOptions>(AdjudicateOptions.Execute)
|
||||||
|
.WithParsed<ImageOptions>(ImageOptions.Execute)
|
||||||
|
.WithParsed<ReplOptions>(ReplOptions.Execute);
|
||||||
}
|
}
|
||||||
}
|
}
|
Loading…
Reference in New Issue