mirror of
https://github.com/Tribufu/TribufuDotNet
synced 2026-08-11 05:41:05 +00:00
Update projects
This commit is contained in:
parent
44dc36430a
commit
93301110b7
101 changed files with 23635 additions and 16252 deletions
|
|
@ -0,0 +1,16 @@
|
|||
// Copyright (c) Tribufu. All Rights Reserved.
|
||||
// SPDX-License-Identifier: MIT
|
||||
|
||||
using Microsoft.Extensions.Configuration;
|
||||
|
||||
namespace Tribufu.Configuration.Extensions
|
||||
{
|
||||
public static class IConfigurationExtensions
|
||||
{
|
||||
public static string? Get(this IConfiguration configuration, string prefix, string key)
|
||||
{
|
||||
var section = configuration.GetSection(prefix);
|
||||
return !section.Exists() ? configuration[$"{prefix}_{key}"] : section[key];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -1,13 +1,14 @@
|
|||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
<PropertyGroup>
|
||||
<PackageId>Tribufu.Configuration</PackageId>
|
||||
<Description>Tribufu Configuration Extensions</Description>
|
||||
<Description>Tribufu Configuration</Description>
|
||||
<PackageReadmeFile>README.md</PackageReadmeFile>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
|
||||
<IsPublishable>false</IsPublishable>
|
||||
<Nullable>enable</Nullable>
|
||||
<OutputType>Library</OutputType>
|
||||
<TargetFrameworks>net6.0</TargetFrameworks>
|
||||
</PropertyGroup>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue