Skip to content

Commit fc067c6

Browse files
authored
Merge pull request #1 from snovak7/main
Preparations for release v0.1.0
2 parents f062d95 + 86ceb0d commit fc067c6

15 files changed

Lines changed: 599 additions & 2 deletions

.editorconfig

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
[*]
2+
charset = utf-8
3+
insert_final_newline = true

.github/workflows/build.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: dotnet build
2+
3+
on: [push]
4+
5+
jobs:
6+
build:
7+
runs-on: ubuntu-latest
8+
strategy:
9+
matrix:
10+
dotnet-version: [ '7.0.x' ]
11+
steps:
12+
- uses: actions/checkout@v3
13+
with:
14+
fetch-depth: '0'
15+
- name: Setup .NET Core SDK ${{ matrix.dotnet-version }}
16+
uses: actions/setup-dotnet@v3
17+
with:
18+
dotnet-version: ${{ matrix.dotnet-version }}
19+
- name: Restore .NET Packages
20+
run: dotnet restore
21+
- name: Build .NET Solution
22+
run: dotnet build --configuration Release --no-restore
23+
- name: Pack .NET Solution
24+
run: dotnet pack --no-build --output pack/
25+
- name: Publish .NET Solution to GitHub Packages
26+
continue-on-error: true
27+
run: dotnet nuget push pack/* --api-key ${{ secrets.GITHUB_TOKEN }} --source "https://nuget.pkg.github.com/${{ github.repository_owner }}/index.json"
28+
- name: Publish .NET Solution to NuGet.org
29+
continue-on-error: true
30+
run: dotnet nuget push pack/* --api-key ${{ secrets.NUGET_ORG_KEY }} --source nuget
31+

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -348,3 +348,6 @@ MigrationBackup/
348348

349349
# Ionide (cross platform F# VS Code tools) working folder
350350
.ionide/
351+
352+
# JetBrains
353+
.idea/

Directory.Build.props

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<Project>
3+
<PropertyGroup>
4+
<RepositoryType>git</RepositoryType>
5+
<RepositoryUrl>https://github.com/escendit/Escendit.Tools.CodeAnalysis.StyleCopAnalyzers</RepositoryUrl>
6+
</PropertyGroup>
7+
</Project>

Directory.Packages.props

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<Project>
3+
<ItemGroup>
4+
<PackageReference Include="Escendit.Tools.Branding" Version="1.0.2">
5+
<PrivateAssets>all</PrivateAssets>
6+
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
7+
</PackageReference>
8+
<PackageReference Include="GitVersion.MsBuild" Version="5.12.0">
9+
<PrivateAssets>all</PrivateAssets>
10+
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
11+
</PackageReference>
12+
</ItemGroup>
13+
</Project>
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
2+
Microsoft Visual Studio Solution File, Format Version 12.00
3+
# Visual Studio Version 17
4+
VisualStudioVersion = 17.0.31903.59
5+
MinimumVisualStudioVersion = 10.0.40219.1
6+
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{A7ECE722-6B13-46DD-BBD2-0BB0DD14D725}"
7+
EndProject
8+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Escendit.Tools.CodeAnalysis.StyleCopAnalyzers", "src\Escendit.Tools.CodeAnalysis.StyleCopAnalyzers\Escendit.Tools.CodeAnalysis.StyleCopAnalyzers.csproj", "{68B6D864-A601-4248-B0AB-BC7047246A62}"
9+
EndProject
10+
Global
11+
GlobalSection(SolutionConfigurationPlatforms) = preSolution
12+
Debug|Any CPU = Debug|Any CPU
13+
Release|Any CPU = Release|Any CPU
14+
EndGlobalSection
15+
GlobalSection(SolutionProperties) = preSolution
16+
HideSolutionNode = FALSE
17+
EndGlobalSection
18+
GlobalSection(NestedProjects) = preSolution
19+
{68B6D864-A601-4248-B0AB-BC7047246A62} = {A7ECE722-6B13-46DD-BBD2-0BB0DD14D725}
20+
EndGlobalSection
21+
GlobalSection(ProjectConfigurationPlatforms) = postSolution
22+
{68B6D864-A601-4248-B0AB-BC7047246A62}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
23+
{68B6D864-A601-4248-B0AB-BC7047246A62}.Debug|Any CPU.Build.0 = Debug|Any CPU
24+
{68B6D864-A601-4248-B0AB-BC7047246A62}.Release|Any CPU.ActiveCfg = Release|Any CPU
25+
{68B6D864-A601-4248-B0AB-BC7047246A62}.Release|Any CPU.Build.0 = Release|Any CPU
26+
EndGlobalSection
27+
EndGlobal

GitVersion.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
branches:
2+
master:
3+
mode: ContinuousDeployment
4+
tag: rc

README.md

Lines changed: 242 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,242 @@
1-
# Escendit.Tools.CodeAnalysis.StyleCopAnalyzers
2-
StyleCop Analyzers Defaults
1+
# NuGet Package: Escendit.Tools.CodeAnalysis.StyleCopAnalyzers
2+
3+
This NuGet package leverages the power of StyleCop Analyzers
4+
to enforce code quality standards that are tailored to the organization's specific needs.
5+
By default,
6+
the package uses a set of analyzer rules that have been configured to align with the organization's coding practices,
7+
ensuring that our code is always compliant and maintainable.
8+
9+
Key features:
10+
11+
- Utilize Roslyn .NET Analyzers for powerful and customizable code analysis
12+
- Defaults suited to the organization's coding practices
13+
- Ensures code compliance and maintainability
14+
15+
## Installation
16+
To install this package, use the NuGet Package Manager Console:
17+
18+
```shell
19+
PM> Install-Package Escendit.Tools.CodeAnalysis.StyleCopAnalyzers
20+
```
21+
Or you can search for "Escendit.Tools.CodeAnalysis.StyleCopAnalyzers"
22+
in the NuGet Package Manager UI and install it from there.
23+
24+
## Usage
25+
After installing the package, the MSBuild and .editorconfig properties will be set automatically.
26+
- You can modify the MSBuild properties by updating the values in your .csproj or .vbproj file.
27+
- You can modify the .editorconfig properties by creating .editorconfig file and overriding the default values.
28+
29+
## Configuration
30+
31+
The NuGet package includes the following default rules and severity levels:
32+
33+
34+
| Rule | Severity | Severity |
35+
|----------|----------|----------|
36+
| SA0001 | error ||
37+
| SA0002 | error ||
38+
| SA1000 | error ||
39+
| SA1001 | error ||
40+
| SA1002 | error ||
41+
| SA1003 | error ||
42+
| SA1004 | error ||
43+
| SA1005 | error ||
44+
| SA1006 | error ||
45+
| SA1007 | error ||
46+
| SA1008 | error ||
47+
| SA1009 | error ||
48+
| SA1010 | error ||
49+
| SA1011 | error ||
50+
| SA1012 | error ||
51+
| SA1013 | error ||
52+
| SA1014 | error ||
53+
| SA1015 | error ||
54+
| SA1016 | error ||
55+
| SA1017 | error ||
56+
| SA1018 | error ||
57+
| SA1019 | error ||
58+
| SA1020 | error ||
59+
| SA1021 | error ||
60+
| SA1022 | error ||
61+
| SA1023 | error ||
62+
| SA1024 | error ||
63+
| SA1025 | error ||
64+
| SA1026 | error ||
65+
| SA1027 | error ||
66+
| SA1028 | error ||
67+
| SA1100 | error ||
68+
| SA1101 | none ||
69+
| SA1102 | error ||
70+
| SA1103 | error ||
71+
| SA1104 | error ||
72+
| SA1105 | error ||
73+
| SA1106 | error ||
74+
| SA1107 | error ||
75+
| SA1108 | error ||
76+
| SA1110 | error ||
77+
| SA1111 | error ||
78+
| SA1112 | error ||
79+
| SA1113 | error ||
80+
| SA1114 | error ||
81+
| SA1115 | error ||
82+
| SA1116 | error ||
83+
| SA1117 | error ||
84+
| SA1118 | error ||
85+
| SA1119 | error ||
86+
| SA1120 | error ||
87+
| SA1121 | error ||
88+
| SA1122 | error ||
89+
| SA1123 | error ||
90+
| SA1124 | error ||
91+
| SA1125 | error ||
92+
| SA1127 | error ||
93+
| SA1128 | error ||
94+
| SA1129 | error ||
95+
| SA1130 | error ||
96+
| SA1131 | error ||
97+
| SA1132 | error ||
98+
| SA1133 | error ||
99+
| SA1134 | error ||
100+
| SA1135 | error ||
101+
| SA1136 | error ||
102+
| SA1137 | error ||
103+
| SA1139 | error ||
104+
| SA1141 | error ||
105+
| SA1142 | error ||
106+
| SA1200 | error ||
107+
| SA1201 | error ||
108+
| SA1202 | error ||
109+
| SA1203 | error ||
110+
| SA1204 | error ||
111+
| SA1205 | error ||
112+
| SA1206 | error ||
113+
| SA1207 | error ||
114+
| SA1208 | error ||
115+
| SA1209 | error ||
116+
| SA1210 | error ||
117+
| SA1211 | error ||
118+
| SA1212 | error ||
119+
| SA1213 | error ||
120+
| SA1214 | error ||
121+
| SA1216 | error ||
122+
| SA1217 | error ||
123+
| SA1300 | none ||
124+
| SA1302 | error ||
125+
| SA1303 | error ||
126+
| SA1304 | error ||
127+
| SA1305 | error ||
128+
| SA1306 | error ||
129+
| SA1307 | error ||
130+
| SA1308 | error ||
131+
| SA1309 | none ||
132+
| SA1310 | error ||
133+
| SA1311 | error ||
134+
| SA1312 | error ||
135+
| SA1313 | error ||
136+
| SA1314 | error ||
137+
| SA1316 | error ||
138+
| SA1400 | error ||
139+
| SA1401 | error ||
140+
| SA1402 | error ||
141+
| SA1403 | error ||
142+
| SA1404 | error ||
143+
| SA1405 | error ||
144+
| SA1406 | error ||
145+
| SA1407 | error ||
146+
| SA1408 | error ||
147+
| SA1410 | error ||
148+
| SA1411 | error ||
149+
| SA1412 | error ||
150+
| SA1413 | error ||
151+
| SA1414 | error ||
152+
| SA1500 | error ||
153+
| SA1501 | error ||
154+
| SA1502 | error ||
155+
| SA1503 | error ||
156+
| SA1504 | error ||
157+
| SA1505 | error ||
158+
| SA1506 | error ||
159+
| SA1507 | error ||
160+
| SA1508 | error ||
161+
| SA1509 | error ||
162+
| SA1510 | error ||
163+
| SA1511 | error ||
164+
| SA1512 | error ||
165+
| SA1513 | error ||
166+
| SA1514 | error ||
167+
| SA1515 | error ||
168+
| SA1516 | error ||
169+
| SA1517 | error ||
170+
| SA1518 | error ||
171+
| SA1519 | error ||
172+
| SA1520 | error ||
173+
| SA1600 | error ||
174+
| SA1601 | error ||
175+
| SA1602 | error ||
176+
| SA1604 | error ||
177+
| SA1605 | error ||
178+
| SA1606 | error ||
179+
| SA1607 | error ||
180+
| SA1608 | error ||
181+
| SA1609 | error ||
182+
| SA1610 | error ||
183+
| SA1611 | error ||
184+
| SA1612 | error ||
185+
| SA1613 | error ||
186+
| SA1614 | error ||
187+
| SA1615 | error ||
188+
| SA1616 | error ||
189+
| SA1617 | error ||
190+
| SA1618 | error ||
191+
| SA1619 | error ||
192+
| SA1620 | error ||
193+
| SA1621 | error ||
194+
| SA1622 | error ||
195+
| SA1623 | error ||
196+
| SA1624 | error ||
197+
| SA1625 | error ||
198+
| SA1626 | error ||
199+
| SA1627 | error ||
200+
| SA1628 | error ||
201+
| SA1629 | error ||
202+
| SA1633 | error ||
203+
| SA1634 | error ||
204+
| SA1635 | error ||
205+
| SA1636 | error ||
206+
| SA1637 | error ||
207+
| SA1638 | error ||
208+
| SA1639 | error ||
209+
| SA1640 | error ||
210+
| SA1641 | error ||
211+
| SA1642 | error ||
212+
| SA1643 | error ||
213+
| SA1648 | error ||
214+
| SA1649 | error ||
215+
| SA1651 | error ||
216+
| SX1101 | error ||
217+
| SX1309 | error ||
218+
| SX1309S | error ||
219+
220+
221+
To modify the severity level of a rule, you can add the following code to your .editorconfig file:
222+
223+
```editorconfig
224+
# dotnet_diagnostic.<Rule>.severity = <Severity>
225+
```
226+
227+
For example, to change the severity level of `SA9999` to "error", add the following line to your .editorconfig file:
228+
229+
```editorconfig
230+
# dotnet_diagnostic.SA9999.severity = error
231+
```
232+
233+
234+
## Contributing
235+
If you find a bug or have a feature request, please create an issue in the GitHub repository.
236+
237+
To contribute code, fork the repository and submit a pull request.
238+
Please ensure that your code follows the project's coding standards and is thoroughly tested.
239+
240+
## License
241+
This package is released under the MIT License. See the LICENSE.txt file for details.
242+

global.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"sdk": {
3+
"version": "7.0.100"
4+
}
5+
}

nuget.config

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<configuration>
3+
<packageSources>
4+
<clear />
5+
<add key="nuget" value="https://api.nuget.org/v3/index.json" />
6+
</packageSources>
7+
</configuration>

0 commit comments

Comments
 (0)