This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
[assembly: CLSCompliant(false)] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8"?> | |
<configuration> | |
<packageSources> | |
<clear /> | |
<add key="MyArtifactory" value="https://my.organazation.dev/artifactory/api/nuget/v3/nuget" protocolVersion="3" /> | |
</packageSources> | |
</configuration> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"sdk": { | |
"version": "7.0.405", | |
"rollForward": "latestMajor", | |
"allowPrerelease": false | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Created by https://www.toptal.com/developers/gitignore/api/rider,csharp,aspnetcore,dotnetcore,visualstudiocode,visualstudio | |
# Edit at https://www.toptal.com/developers/gitignore?templates=rider,csharp,aspnetcore,dotnetcore,visualstudiocode,visualstudio | |
### ASPNETCore ### | |
## Ignore Visual Studio temporary files, build results, and | |
## files generated by popular Visual Studio add-ons. | |
# User-specific files | |
*.suo | |
*.user |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# https://github.com/dotnet/roslyn-analyzers/blob/master/src/Microsoft.CodeAnalysis.BannedApiAnalyzers/BannedApiAnalyzers.Help.md | |
P:System.DateTime.Now;Use System.DateTime.UtcNow instead | |
P:System.DateTimeOffset.Now;Use System.DateTimeOffset.UtcNow instead | |
P:System.DateTimeOffset.DateTime;Use System.DateTimeOffset.UtcDateTime instead | |
#T:Newtonsoft.Json;Don't use Newtonsoft, use System.Text.Json | |
#N:Newtonsoft.Json;Don't use Newtonsoft | |
#T:Newtonsoft.Json.JsonPropertyAttribute;Don't use Newtonsoft | |
#N:Newtonsoft.Json.JsonPropertyAttribute;Don't use Newtonsoft | |
#T:Newtonsoft.Json.JsonConvert;Don't use Newtonsoft | |
#N:Newtonsoft.Json.JsonConvert;Don't use Newtonsoft |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<Project> | |
<ItemGroup> | |
<PackageVersion Include="coverlet.collector" Version="6.0.0" /> | |
<PackageVersion Include="FluentAssertions.Analyzers" Version="0.29.1" /> | |
<PackageVersion Include="xunit.analyzers" Version="1.10.0" /> | |
<PackageVersion Include="xunit.runner.visualstudio" Version="2.5.6" /> | |
<PackageVersion Include="Microsoft.NET.Test.Sdk" Version="17.8.0" /> | |
<PackageVersion Include="coverlet.msbuild" Version="6.0.0" /> | |
<PackageVersion Include="Swashbuckle.AspNetCore" Version="6.5.0" /> | |
<PackageVersion Include="Swashbuckle.AspNetCore.Swagger" Version="6.5.0" /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
; Top-most http://editorconfig.org/ file | |
root = true | |
[*] | |
insert_final_newline = true | |
indent_style = space | |
charset = utf-8 | |
trim_trailing_whitespace = true | |
[*.cs] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<Project> | |
<PropertyGroup> | |
<LangVersion>11.0</LangVersion> | |
<AnalysisLevel>latest</AnalysisLevel> | |
<TreatWarningsAsErrors>true</TreatWarningsAsErrors> | |
<RunAnalyzersDuringBuild>true</RunAnalyzersDuringBuild> | |
<RunAnalyzersDuringLiveAnalysis>true</RunAnalyzersDuringLiveAnalysis> | |
<EnforceCodeStyleInBuild>true</EnforceCodeStyleInBuild> | |
<CodeAnalysisTreatWarningsAsErrors>true</CodeAnalysisTreatWarningsAsErrors> | |
<ManagePackageVersionsCentrally>true</ManagePackageVersionsCentrally> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static partial class TestRegexSourceGenerator | |
{ | |
// The Source Generator generates the code of the method at compile time | |
[RegexGenerator(@"\d+", RegexOptions.Compiled, 50)] | |
private static partial Regex IsDigitRegex(); | |
public static bool IsDigit(string value) | |
{ | |
return IsDigitRegex().IsMatch(value); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static class UserTypeTestEnumExtensions | |
{ | |
public static string StringToFast(this UnitTests.UserTypeTest states) | |
{ | |
return states switch | |
{ | |
UnitTests.UserTypeTest.Men => nameof(UnitTests.UserTypeTest.Men), | |
UnitTests.UserTypeTest.Women => nameof(UnitTests.UserTypeTest.Women), | |
UnitTests.UserTypeTest.None => nameof(UnitTests.UserTypeTest.None), | |
_ => throw new ArgumentOutOfRangeException(nameof(states), states, null) |
NewerOlder