mirror of
https://github.com/jcreek/aspnetcore5-with-postgres-identity-serilog-elasticsearch.git
synced 2026-07-12 18:33:45 +00:00
feat(*): Add base StyleCop analyzer
This commit is contained in:
@@ -0,0 +1,7 @@
|
||||
// This file is used by Code Analysis to maintain SuppressMessage
|
||||
// attributes that are applied to this project.
|
||||
// Project-level suppressions either have no target or are given
|
||||
// a specific target and scoped to a namespace, type, member, etc.
|
||||
|
||||
using System.Diagnostics.CodeAnalysis;
|
||||
|
||||
@@ -6,6 +6,14 @@
|
||||
<DockerDefaultTargetOS>Linux</DockerDefaultTargetOS>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<Content Remove="stylecop.json" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<AdditionalFiles Include="stylecop.json" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Microsoft.AspNetCore.Diagnostics.EntityFrameworkCore" Version="5.0.4" />
|
||||
<PackageReference Include="Microsoft.AspNetCore.Http.Features" Version="5.0.4" />
|
||||
@@ -27,6 +35,10 @@
|
||||
<PackageReference Include="Serilog.Exceptions.EntityFrameworkCore" Version="6.1.0" />
|
||||
<PackageReference Include="Serilog.Sinks.Debug" Version="2.0.0" />
|
||||
<PackageReference Include="Serilog.Sinks.Elasticsearch" Version="8.4.1" />
|
||||
<PackageReference Include="StyleCop.Analyzers" Version="1.1.118">
|
||||
<PrivateAssets>all</PrivateAssets>
|
||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||
</PackageReference>
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
|
||||
@@ -0,0 +1,52 @@
|
||||
{
|
||||
// ACTION REQUIRED: This file was automatically added to your project, but it
|
||||
// will not take effect until additional steps are taken to enable it. See the
|
||||
// following page for additional information:
|
||||
//
|
||||
// https://github.com/DotNetAnalyzers/StyleCopAnalyzers/blob/master/documentation/EnableConfiguration.md
|
||||
"": null,
|
||||
"$schema": "https://raw.githubusercontent.com/DotNetAnalyzers/StyleCopAnalyzers/master/StyleCop.Analyzers/StyleCop.Analyzers/Settings/stylecop.schema.json",
|
||||
"settings": {
|
||||
"documentationRules": {
|
||||
"companyName": "MyCompanyName",
|
||||
"documentationCulture": "en-GB",
|
||||
"documentInterfaces": true,
|
||||
"documentExposedElements": true,
|
||||
"documentInternalElements": true,
|
||||
"documentPrivateElements": true,
|
||||
"documentPrivateFields": false,
|
||||
"headerDecoration": "-----------------------------------------------------------------------",
|
||||
"xmlHeader": true
|
||||
},
|
||||
"layoutRules": {
|
||||
"allowConsecutiveUsings": true,
|
||||
"newlineAtEndOfFile": "require"
|
||||
},
|
||||
"maintainabilityRules": {
|
||||
"topLevelTypes": [
|
||||
"class",
|
||||
"interface"
|
||||
]
|
||||
},
|
||||
"namingRules": {
|
||||
"allowCommonHungarianPrefixes": true,
|
||||
"includeInferredTupleElementNames": true,
|
||||
"tupleElementNameCasing": "PascalCase"
|
||||
},
|
||||
"orderingRules": {
|
||||
"elementOrder": [
|
||||
"kind",
|
||||
"constant",
|
||||
"accessibility",
|
||||
"static",
|
||||
"readonly"
|
||||
],
|
||||
"blankLinesBetweenUsingGroups": "omit",
|
||||
"usingDirectivesPlacement": "outsideNamespace",
|
||||
"systemUsingDirectivesFirst": true
|
||||
},
|
||||
"readabilityRules": {
|
||||
"allowBuiltInTypeAliases": true
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user