AperiodicCode.SourceGenerators.FeatureManagement
1.0.0-next.2
dotnet add package AperiodicCode.SourceGenerators.FeatureManagement --version 1.0.0-next.2
NuGet\Install-Package AperiodicCode.SourceGenerators.FeatureManagement -Version 1.0.0-next.2
<PackageReference Include="AperiodicCode.SourceGenerators.FeatureManagement" Version="1.0.0-next.2"> <PrivateAssets>all</PrivateAssets> <IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets> </PackageReference>
paket add AperiodicCode.SourceGenerators.FeatureManagement --version 1.0.0-next.2
#r "nuget: AperiodicCode.SourceGenerators.FeatureManagement, 1.0.0-next.2"
// Install AperiodicCode.SourceGenerators.FeatureManagement as a Cake Addin #addin nuget:?package=AperiodicCode.SourceGenerators.FeatureManagement&version=1.0.0-next.2&prerelease // Install AperiodicCode.SourceGenerators.FeatureManagement as a Cake Tool #tool nuget:?package=AperiodicCode.SourceGenerators.FeatureManagement&version=1.0.0-next.2&prerelease
AperiodicCode.SourceGenerators.FeatureManagement
Generates constants based on features defined in appsettings.json
.
Pre-requisites
Must include the following in your project file:
<ItemGroup>
<AdditionalFiles Include="appsettings.json" />
</ItemGroup>
Example
Input appsettings.json
:
{
"FeatureManagement": {
"TestFeature1": true,
"TestFeature2": false
}
}
Output:
public static class FeatureConstants
{
public const string TestFeature1 = "TestFeature1";
public const string TestFeature2 = "TestFeature2";
}
Limitations
Only works with appsettings.json
currently. Does not support other files (like appsettings.{Environment}.json
).
Learn more about Target Frameworks and .NET Standard.
This package has no dependencies.
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 |
---|---|---|
1.0.0-next.2 | 1,840 | 7/21/2023 |
1.0.0-next.1 | 97 | 7/21/2023 |
# [1.0.0-next.2](https://github.com/AperiodicCode/SourceGenerators.FeatureManagement/compare/v1.0.0-next.1...v1.0.0-next.2) (2023-07-21)
### Bug Fixes
* attempting to include dependency for nuget ([ce360d7](https://github.com/AperiodicCode/SourceGenerators.FeatureManagement/commit/ce360d796017aa6b433a453a3c5d12090c0c5c84))