Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 16 additions & 7 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -78,13 +78,6 @@ insert_final_newline = false
tab_width = unset
trim_trailing_whitespace = false

[*.{AssemblyAttributes.cs,AssemblyInfo.cs}]
exclude = true

[*.{generated.cs,g.cs}]
exclude = true
generated_code = true

[*.{cs,csx,cake}]

##########################################
Expand Down Expand Up @@ -859,6 +852,15 @@ dotnet_diagnostic.CA2017.severity = warning
# CA2019: ThreadStatic fields should not use inline initialization
dotnet_diagnostic.CA2019.severity = error

# CA2024: Do not use StreamReader.EndOfStream in async methods
dotnet_diagnostic.CA2024.severity = error

# CA2025: Do not pass 'IDisposable' instances into unawaited tasks
dotnet_diagnostic.CA2025.severity = warning

# CA2026: Prefer JsonElement.Parse over JsonDocument.Parse().RootElement
dotnet_diagnostic.CA2025.severity = warning

## Usage rules
# https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/quality-rules/usage-warnings

Expand Down Expand Up @@ -888,3 +890,10 @@ dotnet_diagnostic.CA2260.severity = error

# CA5394: Do not use insecure randomness
dotnet_diagnostic.CA5394.severity = none

[*.{AssemblyAttributes.cs,AssemblyInfo.cs}]
exclude = true

[*.{generated.cs,g.cs}]
exclude = true
generated_code = true
18 changes: 14 additions & 4 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ updates:
directory: "/"
schedule:
interval: "cron"
cronjob: "30 12 * * 7"
cronjob: "30 12 14,28 * *" # At 12:30, on day 14 and 28 of the month
cooldown:
default-days: 5
semver-major-days: 20
Expand All @@ -24,6 +24,13 @@ updates:
- "minor"
- "patch"

major-pkg-updates:
applies-to: version-updates
exclude-patterns:
- "*[Aa]nalyzers*"
update-types:
- "major"

pkg-updates:
applies-to: version-updates
exclude-patterns:
Expand All @@ -37,6 +44,7 @@ updates:
patterns:
- "*[Aa]nalyzers*"
update-types:
- "major"
- "minor"
- "patch"
labels:
Expand All @@ -50,13 +58,14 @@ updates:
# action.yml / action.yaml file from the root directory.
directory: "/"
schedule:
interval: monthly
# Doesn't support SemVer
interval: "cron"
cronjob: "0 8 10,20 * *" # At 08:00, on day 10 and 20 of the month
cooldown:
default-days: 5
groups:
actions-dependencies:
update-types:
- "major"
- "minor"
- "patch"
labels:
Expand All @@ -67,7 +76,8 @@ updates:
open-pull-requests-limit: 2
directory: "/"
schedule:
interval: monthly
interval: "cron"
cronjob: "0 9 20 * *"
cooldown:
default-days: 40
semver-major-days: 30
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ jobs:
with:
cache: true
cache-dependency-path: '**/packages.lock.json'
dotnet-version: '9.0.x'
dotnet-version: '10.0.x'

- id: dotnet-restore
name: Install dependencies
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/dependency-review.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ jobs:
needs: pre_job
if: github.actor != 'dependabot[bot]' && needs.pre_job.outputs.should_skip != 'true'
runs-on: ubuntu-latest
timeout-minutes: 15
timeout-minutes: 15
steps:
- id: checkout
name: 'Checkout Repository'
Expand All @@ -59,7 +59,7 @@ jobs:
with:
cache: true
cache-dependency-path: '**/packages.lock.json'
dotnet-version: '9.0.x'
dotnet-version: '10.0.x'

- id: check-vulnerable
name: Check for vulnerable packages
Expand Down
10 changes: 6 additions & 4 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ jobs:
with:
cache: true
cache-dependency-path: "**/packages.lock.json"
dotnet-version: '9.0.x'
dotnet-version: '10.0.x'

- id: install-dotnet-coverage
name: Install dotnet-coverage tool
Expand Down Expand Up @@ -129,7 +129,7 @@ jobs:
- id: test
name: Test
if: env.ENABLED == '1'
run: dotnet test -s ./cicd.runsettings --configuration $BUILD_CONFIG --no-build --verbosity quiet --logger "GitHubActions;summary.includeNotFoundTests=false" --blame-hang-timeout 10m -- --coverage --coverage-output-format xml --coverage-output coverage.cobertura.xml
run: dotnet test --property:runsetting=./cicd.runsettings --configuration $BUILD_CONFIG --no-build --verbosity quiet --crashdump --hangdump --hangdump-timeout 10m --coverage --coverage-output-format cobertura --coverage-output coverage.cobertura.xml

- id: upload-logs
name: Upload Test Logs
Expand All @@ -148,7 +148,7 @@ jobs:
with:
reports: '**/TestResults/**/coverage.cobertura.xml'
targetdir: '${{ github.workspace }}/coveragereport'
reporttypes: 'MarkdownSummaryGithub;MarkdownAssembliesSummary'
reporttypes: 'Cobertura;MarkdownSummaryGithub;MarkdownAssembliesSummary'
classfilters: '-System.*;-Microsoft.*;-Newtonsoft.*;-System.Text.RegularExpressions.*;-xunit.*;-NUnit.*;-TUnit.*'

- id: upload-codecov
Expand All @@ -157,6 +157,8 @@ jobs:
uses: codecov/[email protected]
with:
flags: unittests
fail_ci_if_error: true
files: ${{ github.workspace }}/coveragereport/Cobertura.xml
verbose: true
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
Expand Down Expand Up @@ -200,5 +202,5 @@ jobs:
with:
name: code-coverage-report-ubuntu
path: |
**/TestResults/**/coverage.cobertura.xml
**/TestResults/**/*.cobertura.xml
coveragereport/*.md
3 changes: 2 additions & 1 deletion .github/workflows/version-sweeper.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: ".NET version sweeper"

# When to run this action:
# - Scheduled on the first of every month
# - Manually runable from the GitHub UI with a reason
# - Manually runnable from the GitHub UI with a reason
on:
schedule:
- cron: "0 0 1 * *"
Expand Down Expand Up @@ -58,6 +58,7 @@ jobs:
env:
UPGRADE_PROJECTS: ${{ steps.dotnet-version-sweeper.outputs.upgrade-projects }}
SUPPORT: ${{ inputs.support }}
DOTNET_CLI_TELEMETRY_OPTOUT: true
run: |
upgradeProjects: "$UPGRADE_PROJECTS"

Expand Down
4 changes: 2 additions & 2 deletions Directory.Build.props
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<Project>
<PropertyGroup>
<Deterministic>true</Deterministic>
<TargetFramework>net9.0</TargetFramework>
<LangVersion>13.0</LangVersion>
<TargetFramework>net10.0</TargetFramework>
<LangVersion>14.0</LangVersion>
<SatelliteResourceLanguages>en</SatelliteResourceLanguages>
<RuntimeIdentifiers>win-x64;linux-x64</RuntimeIdentifiers>
<EnableNETAnalyzers>true</EnableNETAnalyzers>
Expand Down
2 changes: 1 addition & 1 deletion global.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"sdk": {
"version": "9.0.306",
"version": "10.0.0",
"allowPrerelease": false,
"rollForward": "latestMinor"
},
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// Generated by BuilderGenerator
// Assembly: BuilderDemo
// Language version: CSharp13
// Language version: CSharp14
// Source type: Address
//------------------------------------------------------------------------------
// <auto-generated>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// Generated by BuilderGenerator
// Assembly: BuilderDemo
// Language version: CSharp13
// Language version: CSharp14
// Source type: Foo<T>
//------------------------------------------------------------------------------
// <auto-generated>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// Generated by BuilderGenerator
// Assembly: BuilderDemo
// Language version: CSharp13
// Language version: CSharp14
// Source type: Person
//------------------------------------------------------------------------------
// <auto-generated>
Expand Down
6 changes: 3 additions & 3 deletions src/BuilderDemo/packages.lock.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"version": 2,
"dependencies": {
"net9.0": {
"net10.0": {
"IDisposableAnalyzers": {
"type": "Direct",
"requested": "[4.0.8, )",
Expand All @@ -27,7 +27,7 @@
"contentHash": "GI4jcoi6eC9ZhNOQylIBaWOQjyGaR8T6N3tC1u8p3EXfndLCVNNWa+Zp+ocjvvS3kNBN09Zma2HXL0ezO0dRfw=="
}
},
"net9.0/linux-x64": {},
"net9.0/win-x64": {}
"net10.0/linux-x64": {},
"net10.0/win-x64": {}
}
}
73 changes: 7 additions & 66 deletions tests/BuilderGenerator.Tests/packages.lock.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"version": 2,
"dependencies": {
"net9.0": {
"net10.0": {
"GitHubActionsTestLogger": {
"type": "Direct",
"requested": "[2.4.1, )",
Expand All @@ -24,9 +24,7 @@
"contentHash": "568a6wcTivauIhbeWcCwfWwIn7UV7MeHEBvFB2uzGIpM2OhJ4eM/FZ8KS0yhPoNxnSpjGzz7x7CIjTxhslojQA==",
"dependencies": {
"Microsoft.CodeAnalysis.Analyzers": "3.11.0",
"Microsoft.CodeAnalysis.Common": "[4.14.0]",
"System.Collections.Immutable": "9.0.0",
"System.Reflection.Metadata": "9.0.0"
"Microsoft.CodeAnalysis.Common": "[4.14.0]"
}
},
"Microsoft.Testing.Extensions.CodeCoverage": {
Expand Down Expand Up @@ -129,9 +127,7 @@
"resolved": "4.14.0",
"contentHash": "PC3tuwZYnC+idaPuoC/AZpEdwrtX7qFpmnrfQkgobGIWiYmGi5MCRtl5mx6QrfMGQpK78X2lfIEoZDLg/qnuHg==",
"dependencies": {
"Microsoft.CodeAnalysis.Analyzers": "3.11.0",
"System.Collections.Immutable": "9.0.0",
"System.Reflection.Metadata": "9.0.0"
"Microsoft.CodeAnalysis.Analyzers": "3.11.0"
}
},
"Microsoft.Diagnostics.NETCore.Client": {
Expand All @@ -150,14 +146,7 @@
"Microsoft.Extensions.DependencyModel": {
"type": "Transitive",
"resolved": "6.0.2",
"contentHash": "HS5YsudCGSVoCVdsYJ5FAO9vx0z04qSAXgVzpDJSQ1/w/X9q8hrQVGU2p+Yfui+2KcXLL+Zjc0SX3yJWtBmYiw==",
"dependencies": {
"System.Buffers": "4.5.1",
"System.Memory": "4.5.4",
"System.Runtime.CompilerServices.Unsafe": "6.0.0",
"System.Text.Encodings.Web": "6.0.1",
"System.Text.Json": "6.0.11"
}
"contentHash": "HS5YsudCGSVoCVdsYJ5FAO9vx0z04qSAXgVzpDJSQ1/w/X9q8hrQVGU2p+Yfui+2KcXLL+Zjc0SX3yJWtBmYiw=="
},
"Microsoft.Extensions.Logging.Abstractions": {
"type": "Transitive",
Expand Down Expand Up @@ -197,31 +186,18 @@
"Microsoft.TestPlatform.ObjectModel": {
"type": "Transitive",
"resolved": "17.10.0",
"contentHash": "KkwhjQevuDj0aBRoPLY6OLAhGqbPUEBuKLbaCs0kUVw29qiOYncdORd4mLVJbn9vGZ7/iFGQ/+AoJl0Tu5Umdg==",
"dependencies": {
"System.Reflection.Metadata": "1.6.0"
}
"contentHash": "KkwhjQevuDj0aBRoPLY6OLAhGqbPUEBuKLbaCs0kUVw29qiOYncdORd4mLVJbn9vGZ7/iFGQ/+AoJl0Tu5Umdg=="
},
"SimpleInfoName": {
"type": "Transitive",
"resolved": "3.1.2",
"contentHash": "/OoEZQxSW6DeTJ9nfrg8BLCOCWpxBiWHV4NkG3t+Xpe8tvzm7yCwKwxkhpauMl3fg9OjlIjJMKX61H6VavLkrw=="
},
"System.Buffers": {
"type": "Transitive",
"resolved": "4.5.1",
"contentHash": "Rw7ijyl1qqRS0YQD/WycNst8hUUMgrMH4FCn1nNm27M4VxchZ1js3fVjQaANHO5f3sN4isvP4a+Met9Y4YomAg=="
},
"System.CodeDom": {
"type": "Transitive",
"resolved": "8.0.0",
"contentHash": "WTlRjL6KWIMr/pAaq3rYqh0TJlzpouaQ/W1eelssHgtlwHAH25jXTkUphTYx9HaIIf7XA6qs/0+YhtLEQRkJ+Q=="
},
"System.Collections.Immutable": {
"type": "Transitive",
"resolved": "9.0.0",
"contentHash": "QhkXUl2gNrQtvPmtBTQHb0YsUrDiDQ2QS09YbtTTiSjGcf7NBqtYbrG/BE06zcBPCKEwQGzIv13IVdXNOSub2w=="
},
"System.Management": {
"type": "Transitive",
"resolved": "8.0.0",
Expand All @@ -230,31 +206,6 @@
"System.CodeDom": "8.0.0"
}
},
"System.Memory": {
"type": "Transitive",
"resolved": "4.5.4",
"contentHash": "1MbJTHS1lZ4bS4FmsJjnuGJOu88ZzTT2rLvrhW7Ygic+pC0NWA+3hgAen0HRdsocuQXCkUTdFn9yHJJhsijDXw=="
},
"System.Reflection.Metadata": {
"type": "Transitive",
"resolved": "9.0.0",
"contentHash": "ANiqLu3DxW9kol/hMmTWbt3414t9ftdIuiIU7j80okq2YzAueo120M442xk1kDJWtmZTqWQn7wHDvMRipVOEOQ=="
},
"System.Runtime.CompilerServices.Unsafe": {
"type": "Transitive",
"resolved": "6.0.0",
"contentHash": "/iUeP3tq1S0XdNNoMz5C9twLSrM/TH+qElHkXWaPvuNOt+99G75NrV0OS2EqHx5wMN7popYjpc8oTjC1y16DLg=="
},
"System.Text.Encodings.Web": {
"type": "Transitive",
"resolved": "6.0.1",
"contentHash": "E5M5AE2OUTlCrf4omZvzzziUJO9CofBl+lXHaN5IKePPJvHqYFYYpaDPgCpR4VwaFbEebfnjOxxEBtPtsqAxpQ=="
},
"System.Text.Json": {
"type": "Transitive",
"resolved": "6.0.11",
"contentHash": "xqC1HIbJMBFhrpYs76oYP+NAskNVjc6v73HqLal7ECRDPIp4oRU5pPavkD//vNactCn9DA2aaald/I5N+uZ5/g=="
},
"TUnit.Assertions": {
"type": "Transitive",
"resolved": "1.2.11",
Expand Down Expand Up @@ -300,7 +251,7 @@
"contentHash": "GI4jcoi6eC9ZhNOQylIBaWOQjyGaR8T6N3tC1u8p3EXfndLCVNNWa+Zp+ocjvvS3kNBN09Zma2HXL0ezO0dRfw=="
}
},
"net9.0/linux-x64": {
"net10.0/linux-x64": {
"Microsoft.Testing.Extensions.CodeCoverage": {
"type": "Direct",
"requested": "[18.1.0, )",
Expand All @@ -319,14 +270,9 @@
"dependencies": {
"System.CodeDom": "8.0.0"
}
},
"System.Text.Encodings.Web": {
"type": "Transitive",
"resolved": "6.0.1",
"contentHash": "E5M5AE2OUTlCrf4omZvzzziUJO9CofBl+lXHaN5IKePPJvHqYFYYpaDPgCpR4VwaFbEebfnjOxxEBtPtsqAxpQ=="
}
},
"net9.0/win-x64": {
"net10.0/win-x64": {
"Microsoft.Testing.Extensions.CodeCoverage": {
"type": "Direct",
"requested": "[18.1.0, )",
Expand All @@ -345,11 +291,6 @@
"dependencies": {
"System.CodeDom": "8.0.0"
}
},
"System.Text.Encodings.Web": {
"type": "Transitive",
"resolved": "6.0.1",
"contentHash": "E5M5AE2OUTlCrf4omZvzzziUJO9CofBl+lXHaN5IKePPJvHqYFYYpaDPgCpR4VwaFbEebfnjOxxEBtPtsqAxpQ=="
}
}
}
Expand Down
Loading