Shoko.BuildTools.Targets
0.7.2
dotnet add package Shoko.BuildTools.Targets --version 0.7.2
NuGet\Install-Package Shoko.BuildTools.Targets -Version 0.7.2
<PackageReference Include="Shoko.BuildTools.Targets" Version="0.7.2"> <PrivateAssets>all</PrivateAssets> <IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets> </PackageReference>
<PackageVersion Include="Shoko.BuildTools.Targets" Version="0.7.2" />
<PackageReference Include="Shoko.BuildTools.Targets"> <PrivateAssets>all</PrivateAssets> <IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets> </PackageReference>
paket add Shoko.BuildTools.Targets --version 0.7.2
#r "nuget: Shoko.BuildTools.Targets, 0.7.2"
#:package Shoko.BuildTools.Targets@0.7.2
#addin nuget:?package=Shoko.BuildTools.Targets&version=0.7.2
#tool nuget:?package=Shoko.BuildTools.Targets&version=0.7.2
Shoko.BuildTools.Targets
MSBuild targets for Shoko Server plugin projects. On every build they stamp the assembly metadata the server reads from a plugin: its identity (from the project, manifest.json or the source), its dependencies (from the project), the runtime identifier, the release channel and the source revision. They also turn on EnableDynamicLoading unless the project sets it, so the plugin's own NuGet dependencies are copied into its output as the server expects; a project that is not a plugin sets it to false.
Getting started
<PackageReference Include="Shoko.BuildTools.Targets" Version="..." PrivateAssets="All" />
Nothing else is needed; the targets run as part of dotnet build. To also pack a release archive and update a release manifest, use the Shoko.BuildTools tool.
Plugin metadata
The plugin's identity and tags come from its manifest.json, or from its source without one, unless the project states them as PluginID, PluginName, PluginOverview, PluginNamespace and PluginTags properties. The namespace is optional: a short, unique kebab-case name of 2 to 32 characters (^[a-z][a-z0-9]*(-[a-z0-9]+)*$) the plugin reserves for itself, which other plugins and conventions may key off, stamped as PackageNamespace; shoko, core and plugin are reserved, and a bad one stops the build. Its dependencies, the plugins the server loads before it, belong in the project, one PluginDependency item per plugin:
<ItemGroup>
<PluginDependency Include="0f8a1c2e-1111-2222-3333-444455556666" Version="^1.2.0" />
<PluginDependency Include="7d3b9f40-aaaa-bbbb-cccc-ddddeeeeffff" Version=">=2.0" Optional="true" />
</ItemGroup>
Include is the plugin's ID, Version a range (>=1.0.0, ^1.0.0, ~1.0.0 or 1.0.0), and Optional true or false, false when left out. The PluginDependencies property, the same list as one string, replaces the items. A manifest's top-level dependencies are not read. A bad item stops the build, naming it. See Plugin metadata and Dependencies in the guide.
Generated plugin class and images
A project setting PluginGenerateClass to true gets its IPlugin class generated: a partial class Plugin in its RootNamespace (or PluginClassName), whose ID, name and description come from the stamped identity. Add a main configuration or behaviour in a partial class of your own; with no other code, it is a meta plugin that only brings in its PluginDependency items. The targets detect that, with no property to set, and stamp PackageIsMeta as true or false, which the server shows as IsMeta. PluginIcon and PluginThumbnail name the image files to embed for the server to show. See Generated plugin class and Plugin images in the guide.
Documentation
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net10.0
- Microsoft.Build.Framework (>= 18.9.6)
- Microsoft.Build.Utilities.Core (>= 18.9.6)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 0.7.2 | 66 | 10/29/2026 |
| 0.7.1 | 183 | 10/27/2026 |
| 0.7.0 | 89 | 10/27/2026 |
| 0.6.1 | 121 | 10/25/2026 |
| 0.6.0 | 593 | 10/25/2026 |
| 0.5.0 | 372 | 10/20/2026 |
| 0.4.0 | 83 | 10/20/2026 |
| 0.3.4 | 139 | 10/16/2026 |
| 0.3.3 | 117 | 10/13/2026 |
| 0.3.2 | 1,302 | 10/3/2026 |
| 0.3.1 | 371 | 9/19/2026 |
| 0.3.0 | 1,761 | 9/11/2026 |
| 0.2.1 | 884 | 8/17/2026 |
| 0.2.0 | 128 | 8/14/2026 |
| 0.1.0 | 1,390 | 7/25/2026 |