-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
namespace Doki.Output.ClassLibrary; | ||
|
||
[DokiOutput("Doki.Output.ClassLibrary")] | ||
public sealed class ClassLibraryOutput(OutputContext context) : OutputBase<ClassLibraryOutputOptions>(context) | ||
{ | ||
public override async Task WriteAsync(ContentList contentList, CancellationToken cancellationToken = default) | ||
Check warning on line 6 in src/Doki.Output.ClassLibrary/ClassLibraryOutput.cs GitHub Actions / Test
Check warning on line 6 in src/Doki.Output.ClassLibrary/ClassLibraryOutput.cs GitHub Actions / Test
Check warning on line 6 in src/Doki.Output.ClassLibrary/ClassLibraryOutput.cs GitHub Actions / Test
|
||
{ | ||
ArgumentNullException.ThrowIfNull(contentList); | ||
} | ||
|
||
public override async Task WriteAsync(TypeDocumentation typeDocumentation, | ||
Check warning on line 11 in src/Doki.Output.ClassLibrary/ClassLibraryOutput.cs GitHub Actions / Test
Check warning on line 11 in src/Doki.Output.ClassLibrary/ClassLibraryOutput.cs GitHub Actions / Test
Check warning on line 11 in src/Doki.Output.ClassLibrary/ClassLibraryOutput.cs GitHub Actions / Test
|
||
CancellationToken cancellationToken = default) | ||
{ | ||
ArgumentNullException.ThrowIfNull(typeDocumentation); | ||
} | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
using System.Text.Json.Serialization; | ||
|
||
namespace Doki.Output.ClassLibrary; | ||
|
||
public sealed record ClassLibraryOutputOptions : OutputOptions | ||
{ | ||
[JsonPropertyName("namespace")] public string Namespace { get; init; } | ||
|
||
[JsonPropertyName("projectName")] public string? ProjectName { get; init; } | ||
|
||
[JsonPropertyName("targetFramework")] public string TargetFramework { get; init; } | ||
|
||
[JsonPropertyName("targetFrameworks")] public string[]? TargetFrameworks { get; init; } | ||
|
||
public ClassLibraryOutputOptions() | ||
{ | ||
Namespace = "Doki.Content"; | ||
TargetFramework = "net8.0"; | ||
} | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
<Project Sdk="Microsoft.NET.Sdk"> | ||
|
||
<PropertyGroup> | ||
<PackageId>Doki.Output.ClassLibrary</PackageId> | ||
<Authors>david@vollmers.org</Authors> | ||
<Copyright>David Vollmers</Copyright> | ||
<Description>Doki Class Library Generator</Description> | ||
<PackageProjectUrl>https://github.com/DavidVollmers/doki</PackageProjectUrl> | ||
<PackageLicenseExpression>MIT</PackageLicenseExpression> | ||
<PackageReadmeFile>README.md</PackageReadmeFile> | ||
<PackageIcon>logo-64x64.png</PackageIcon> | ||
<RepositoryType>git</RepositoryType> | ||
<RepositoryUrl>https://github.com/DavidVollmers/doki.git</RepositoryUrl> | ||
<TargetFrameworks>net6.0;net7.0;net8.0</TargetFrameworks> | ||
<LangVersion>12</LangVersion> | ||
<ImplicitUsings>enable</ImplicitUsings> | ||
<Nullable>enable</Nullable> | ||
<PackageOutputPath>..\..\nuget</PackageOutputPath> | ||
</PropertyGroup> | ||
|
||
<ItemGroup> | ||
<ProjectReference Include="..\Doki.Output.Abstractions\Doki.Output.Abstractions.csproj"/> | ||
</ItemGroup> | ||
|
||
<ItemGroup> | ||
<None Include="..\..\README.md" Pack="true" PackagePath="\"/> | ||
<None Include="..\..\LICENSE.txt" Pack="true" PackagePath="\"/> | ||
<None Include="..\..\assets\logo-64x64.png" Pack="true" PackagePath="\"/> | ||
</ItemGroup> | ||
|
||
</Project> |