Init
This commit is contained in:
parent
0d1e09ce3b
commit
42628581a9
7
.gitignore
vendored
Normal file
7
.gitignore
vendored
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
.idea
|
||||||
|
|
||||||
|
SessionZero.SzfCli/bin
|
||||||
|
SessionZero.SzfCli/obj
|
||||||
|
|
||||||
|
SessionZero.SzfLib/bin
|
||||||
|
SessionZero.SzfLib/obj
|
29
SessionZero.SzfCli/Program.cs
Normal file
29
SessionZero.SzfCli/Program.cs
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
// See https://aka.ms/new-console-template for more information
|
||||||
|
|
||||||
|
using Spectre.Console;
|
||||||
|
|
||||||
|
AnsiConsole.MarkupLine("[deepskyblue4_1]\n\n" +
|
||||||
|
" █████████ ███████████ ███████████ █████████ █████ █████\n" +
|
||||||
|
" ███░░░░░███░█░░░░░░███ ░░███░░░░░░█ ███░░░░░███░░███ ░░███ \n" +
|
||||||
|
"░███ ░░░ ░ ███░ ░███ █ ░ ███ ░░░ ░███ ░███ \n" +
|
||||||
|
"░░█████████ ███ ░███████ ░███ ░███ ░███ \n" +
|
||||||
|
" ░░░░░░░░███ ███ ░███░░░█ ░███ ░███ ░███ \n" +
|
||||||
|
" ███ ░███ ████ █ ░███ ░ ░░███ ███ ░███ █ ░███ \n" +
|
||||||
|
"░░█████████ ███████████ █████ ░░█████████ ███████████ █████\n" +
|
||||||
|
" ░░░░░░░░░ ░░░░░░░░░░░ ░░░░░ ░░░░░░░░░ ░░░░░░░░░░░ ░░░░░ \n\n[/]"
|
||||||
|
);
|
||||||
|
|
||||||
|
|
||||||
|
AnsiConsole.MarkupLine("[deepskyblue4_2]A tool for testing the SessionZero SZF Parser[/]");
|
||||||
|
AnsiConsole.MarkupLine("See [blue][link]https://sessionzero.app/szf-docs.html[/][/] for SZF documentation.");
|
||||||
|
|
||||||
|
struct SZColors
|
||||||
|
{
|
||||||
|
public static readonly Color BackgroundColor = Color.Grey19;
|
||||||
|
public static readonly Color PrimaryColor = Color.SteelBlue;
|
||||||
|
public static readonly Color PrimaryColorLight = Color.SlateBlue1;
|
||||||
|
public static readonly Color SecondaryColor = Color.NavyBlue;
|
||||||
|
public static readonly Color AccentColor = Color.DeepSkyBlue4_2;
|
||||||
|
public static readonly Color TextColor = Color.White;
|
||||||
|
public static readonly Color HeadingColor = Color.LightSteelBlue;
|
||||||
|
}
|
19
SessionZero.SzfCli/SessionZero.SzfCli.csproj
Normal file
19
SessionZero.SzfCli/SessionZero.SzfCli.csproj
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
|
<PropertyGroup>
|
||||||
|
<OutputType>Exe</OutputType>
|
||||||
|
<TargetFramework>net9.0</TargetFramework>
|
||||||
|
<ImplicitUsings>enable</ImplicitUsings>
|
||||||
|
<Nullable>enable</Nullable>
|
||||||
|
</PropertyGroup>
|
||||||
|
|
||||||
|
<ItemGroup>
|
||||||
|
<ProjectReference Include="..\SessionZero.SzfLib\SessionZero.SzfLib.csproj" />
|
||||||
|
</ItemGroup>
|
||||||
|
|
||||||
|
<ItemGroup>
|
||||||
|
<PackageReference Include="Spectre.Console" Version="0.50.0" />
|
||||||
|
<PackageReference Include="Spectre.Console.Cli" Version="0.50.0" />
|
||||||
|
</ItemGroup>
|
||||||
|
|
||||||
|
</Project>
|
6
SessionZero.SzfLib/Objects/ISzfObject.cs
Normal file
6
SessionZero.SzfLib/Objects/ISzfObject.cs
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
namespace SessionZero.SzfLib.Objects;
|
||||||
|
|
||||||
|
public interface ISzfObject
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
6
SessionZero.SzfLib/Objects/SzfObject.cs
Normal file
6
SessionZero.SzfLib/Objects/SzfObject.cs
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
namespace SessionZero.SzfLib.Objects;
|
||||||
|
|
||||||
|
public class SzfObject : ISzfObject
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
15
SessionZero.SzfLib/SessionZero.SzfLib.csproj
Normal file
15
SessionZero.SzfLib/SessionZero.SzfLib.csproj
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
|
<PropertyGroup>
|
||||||
|
<TargetFramework>net9.0</TargetFramework>
|
||||||
|
<ImplicitUsings>enable</ImplicitUsings>
|
||||||
|
<Nullable>enable</Nullable>
|
||||||
|
</PropertyGroup>
|
||||||
|
|
||||||
|
<ItemGroup>
|
||||||
|
<Folder Include="File\" />
|
||||||
|
<Folder Include="Generator\" />
|
||||||
|
<Folder Include="Parser\" />
|
||||||
|
</ItemGroup>
|
||||||
|
|
||||||
|
</Project>
|
21
SessionZero.SzfLib/SzfObjectAttribute.cs
Normal file
21
SessionZero.SzfLib/SzfObjectAttribute.cs
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
namespace SessionZero.SzfLib;
|
||||||
|
|
||||||
|
[AttributeUsage(AttributeTargets.Class, Inherited = false, AllowMultiple = false)]
|
||||||
|
public class SzfObjectAttribute : Attribute
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// The unique identifier for the SzfObject type (e.g., "dataset", "character_template", "character").
|
||||||
|
/// This is used in the `!tpye` header of the SZF file to identify the type of SzfObject.
|
||||||
|
/// </summary>
|
||||||
|
public required string TypeIdentifier { get; set; }
|
||||||
|
|
||||||
|
public SzfObjectAttribute(string typeIdentifier)
|
||||||
|
{
|
||||||
|
if (string.IsNullOrWhiteSpace(typeIdentifier))
|
||||||
|
{
|
||||||
|
throw new ArgumentException("Type identifier cannot be null or whitespace.", nameof(typeIdentifier));
|
||||||
|
}
|
||||||
|
|
||||||
|
TypeIdentifier = typeIdentifier;
|
||||||
|
}
|
||||||
|
}
|
22
SessionZero.SzfToolkit.sln
Normal file
22
SessionZero.SzfToolkit.sln
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
|
||||||
|
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||||
|
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SessionZero.SzfLib", "SessionZero.SzfLib\SessionZero.SzfLib.csproj", "{5BBC117D-F751-41AE-BA6D-4F99A9D2459D}"
|
||||||
|
EndProject
|
||||||
|
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SessionZero.SzfCli", "SessionZero.SzfCli\SessionZero.SzfCli.csproj", "{8540219D-5605-4E8A-83A5-7E38245458A5}"
|
||||||
|
EndProject
|
||||||
|
Global
|
||||||
|
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||||
|
Debug|Any CPU = Debug|Any CPU
|
||||||
|
Release|Any CPU = Release|Any CPU
|
||||||
|
EndGlobalSection
|
||||||
|
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||||
|
{5BBC117D-F751-41AE-BA6D-4F99A9D2459D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||||
|
{5BBC117D-F751-41AE-BA6D-4F99A9D2459D}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||||
|
{5BBC117D-F751-41AE-BA6D-4F99A9D2459D}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||||
|
{5BBC117D-F751-41AE-BA6D-4F99A9D2459D}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||||
|
{8540219D-5605-4E8A-83A5-7E38245458A5}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||||
|
{8540219D-5605-4E8A-83A5-7E38245458A5}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||||
|
{8540219D-5605-4E8A-83A5-7E38245458A5}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||||
|
{8540219D-5605-4E8A-83A5-7E38245458A5}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||||
|
EndGlobalSection
|
||||||
|
EndGlobal
|
Loading…
Reference in New Issue
Block a user