Skip to content

Commit 55d9ab3

Browse files
authored
Downgrade three rules after discussion with team (#16)
1 parent 2662264 commit 55d9ab3

5 files changed

Lines changed: 47 additions & 18 deletions

File tree

.github/workflows/cd-production.yml

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,7 @@ env:
99
ARTIFACTS_FEED_URL: https://api.nuget.org/v3/index.json
1010

1111
jobs:
12-
publish:
13-
name: build, pack & publish
12+
pack-and-publish:
1413
runs-on: ubuntu-latest
1514
steps:
1615
- name: Checkout
@@ -35,3 +34,12 @@ jobs:
3534
run: dotnet nuget push --skip-duplicate -s $ARTIFACTS_FEED_URL -k $NUGET_AUTH_TOKEN **/*.nupkg
3635
env:
3736
NUGET_AUTH_TOKEN: ${{ secrets.NUGET_API_KEY_NEOLUTION }}
37+
38+
notify:
39+
needs: [pack-and-publish]
40+
runs-on: ubuntu-latest
41+
steps:
42+
- uses: neolution-ch/action-release-notifier@v1
43+
with:
44+
slack-token: ${{ secrets.SLACK_RELEASE_NOTIFIER_TOKEN }}
45+
slack-channel-ids: "CD34NHYN6"

.github/workflows/ci.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,7 @@ on:
88
workflow_dispatch:
99

1010
jobs:
11-
publish:
12-
name: build & pack
11+
pack:
1312
runs-on: ubuntu-latest
1413
steps:
1514
- name: Checkout

CHANGELOG.md

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,21 @@ and adheres to a project-specific [Versioning](/README.md).
77

88
## [Unreleased]
99

10+
### Added
11+
12+
- Notification for Slack channel upon new releases
13+
14+
### Changed
15+
16+
- Changed "S3242: Method parameters should be declared with base types" to `suggestion`
17+
- Changed "S3257: Declarations and initializations should be as concise as possible" to `suggestion`
18+
- Changed "S3267: Loops should be simplified with "LINQ" expressions" to `suggestion`
19+
1020
## [3.0.0] - 2023-06-28
1121

1222
### Changed
1323

14-
- Stopped changing all rules to error first and instead use the default rulesets of the Analyzers as the base ru
24+
- Stopped changing all rules to error first and instead use the default rulesets of the Analyzers as the base rules
1525
- Migrate from \*.ruleset files to \*.globalconfig files
1626
- Migrate from \*.targets to \*. props files
1727
- Simplified and decluttered README file

build/Neolution.Tests.globalconfig

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -266,6 +266,18 @@ dotnet_diagnostic.CA2007.severity = warning
266266
; Exceptions can be configured in stylecop.json
267267
dotnet_diagnostic.SA1412.severity = warning
268268

269+
# S3242: Method parameters should be declared with base types
270+
; False positive with IEnumerable<T> that could lead to multiple enumerations. This should be only applied on Developers discretion.
271+
dotnet_diagnostic.S3242.severity = suggestion
272+
273+
# S3257: Declarations and initializations should be as concise as possible
274+
; In some cases developers may prefer the verbosity of a unused parameter over the easier readability of a discard.
275+
dotnet_diagnostic.S3257.severity = suggestion
276+
277+
# S3267: Loops should be simplified with "LINQ" expressions
278+
; This can be an annoying rule in cases where it does not really improve readability or even worsens it.
279+
dotnet_diagnostic.S3267.severity = suggestion
280+
269281
# S107: Methods should not have too many parameters
270282
dotnet_diagnostic.S107.severity = warning
271283

@@ -443,18 +455,12 @@ dotnet_diagnostic.S3234.severity = error
443455
# S3240: The simplest possible condition syntax should be used
444456
dotnet_diagnostic.S3240.severity = warning
445457

446-
# S3242: Method parameters should be declared with base types
447-
dotnet_diagnostic.S3242.severity = warning
448-
449458
# S3253: Constructor and destructor declarations should not be redundant
450459
dotnet_diagnostic.S3253.severity = warning
451460

452461
# S3254: Default parameter values should not be passed as arguments
453462
dotnet_diagnostic.S3254.severity = warning
454463

455-
# S3257: Declarations and initializations should be as concise as possible
456-
dotnet_diagnostic.S3257.severity = warning
457-
458464
# S3353: Unchanged local variables should be "const"
459465
dotnet_diagnostic.S3353.severity = warning
460466

build/Neolution.globalconfig

Lines changed: 13 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Top level entry required to mark this as a global AnalyzerConfig file
1+
# Top level entry required to mark this as a global AnalyzerConfig file
22
# NOTE: Do not create section headers for configuration entries
33
is_global = true
44

@@ -226,6 +226,18 @@ dotnet_diagnostic.CA2007.severity = warning
226226
; Exceptions can be configured in stylecop.json
227227
dotnet_diagnostic.SA1412.severity = warning
228228

229+
# S3242: Method parameters should be declared with base types
230+
; False positive with IEnumerable<T> that could lead to multiple enumerations. This should be only applied on Developers discretion.
231+
dotnet_diagnostic.S3242.severity = suggestion
232+
233+
# S3257: Declarations and initializations should be as concise as possible
234+
; In some cases developers may prefer the verbosity of a unused parameter over the easier readability of a discard.
235+
dotnet_diagnostic.S3257.severity = suggestion
236+
237+
# S3267: Loops should be simplified with "LINQ" expressions
238+
; This can be an annoying rule in cases where it does not really improve readability or even worsens it.
239+
dotnet_diagnostic.S3267.severity = suggestion
240+
229241
# S107: Methods should not have too many parameters
230242
dotnet_diagnostic.S107.severity = warning
231243

@@ -403,18 +415,12 @@ dotnet_diagnostic.S3234.severity = error
403415
# S3240: The simplest possible condition syntax should be used
404416
dotnet_diagnostic.S3240.severity = warning
405417

406-
# S3242: Method parameters should be declared with base types
407-
dotnet_diagnostic.S3242.severity = warning
408-
409418
# S3253: Constructor and destructor declarations should not be redundant
410419
dotnet_diagnostic.S3253.severity = warning
411420

412421
# S3254: Default parameter values should not be passed as arguments
413422
dotnet_diagnostic.S3254.severity = warning
414423

415-
# S3257: Declarations and initializations should be as concise as possible
416-
dotnet_diagnostic.S3257.severity = warning
417-
418424
# S3353: Unchanged local variables should be "const"
419425
dotnet_diagnostic.S3353.severity = warning
420426

0 commit comments

Comments
 (0)