mirror of
https://github.com/Tyrrrz/CliFx.git
synced 2025-10-25 15:19:17 +00:00
Disable nullability checks for older target frameworks
This commit is contained in:
@@ -18,6 +18,11 @@
|
||||
<SymbolPackageFormat>snupkg</SymbolPackageFormat>
|
||||
</PropertyGroup>
|
||||
|
||||
<!-- Disable nullability warnings on older frameworks because there is no nullability info for BCL -->
|
||||
<PropertyGroup Condition="'$(TargetFramework)' == 'netstandard2.0' or '$(TargetFramework)' == 'net45'">
|
||||
<Nullable>annotations</Nullable>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<AssemblyAttribute Include="System.Runtime.CompilerServices.InternalsVisibleToAttribute">
|
||||
<_Parameter1>$(AssemblyName).Tests</_Parameter1>
|
||||
|
||||
@@ -210,8 +210,8 @@ namespace CliFx.Domain
|
||||
type,
|
||||
attribute?.Name,
|
||||
attribute?.Description,
|
||||
parameters,
|
||||
options
|
||||
parameters!,
|
||||
options!
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -279,9 +279,9 @@ namespace CliFx.Domain
|
||||
foreach (var childCommand in childCommands)
|
||||
{
|
||||
var relativeCommandName =
|
||||
string.IsNullOrWhiteSpace(childCommand.Name) || string.IsNullOrWhiteSpace(command.Name)
|
||||
? childCommand.Name
|
||||
: childCommand.Name.Substring(command.Name.Length + 1);
|
||||
!string.IsNullOrWhiteSpace(command.Name)
|
||||
? childCommand.Name!.Substring(command.Name.Length + 1)
|
||||
: childCommand.Name!;
|
||||
|
||||
// Name
|
||||
RenderIndent();
|
||||
|
||||
Reference in New Issue
Block a user