-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #122 from bmazzarol/chore/ci
feat: upgrade to dotnet 8
- Loading branch information
Showing
24 changed files
with
198 additions
and
442 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
version: 2 | ||
updates: | ||
- package-ecosystem: "nuget" | ||
directory: "/" | ||
- package-ecosystem: nuget | ||
directory: / | ||
schedule: | ||
interval: "monthly" | ||
interval: monthly |
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,12 @@ | ||
name: "Check C# Formatting" | ||
name: Check C# Formatting | ||
|
||
on: | ||
pull_request: | ||
branches: [ 'main' ] | ||
branches: [ main ] | ||
|
||
jobs: | ||
check_formatting: | ||
runs-on: ubuntu-latest | ||
name: Check C# Formatting | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
- name: Setup .NET | ||
uses: actions/setup-dotnet@v3 | ||
with: | ||
dotnet-version: | | ||
6.0.x | ||
7.0.x | ||
- name: Install dotnet Tooling | ||
run: dotnet tool restore | ||
- name: Check format | ||
run: dotnet csharpier . --check | ||
- uses: bmazzarol/bmazzarol/.github/actions/check-code-format@main |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,12 @@ | ||
name: "Check Commit Message" | ||
name: Check Commit Message | ||
|
||
on: | ||
pull_request: | ||
branches: [ 'main' ] | ||
branches: [ main ] | ||
|
||
jobs: | ||
commitlint: | ||
if: ${{ github.actor != 'dependabot[bot]' }} | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
- uses: wagoid/commitlint-github-action@v5 | ||
- uses: bmazzarol/bmazzarol/.github/actions/check-commit-message@main |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,21 @@ | ||
name: "Check Markdown" | ||
name: Check Markdown | ||
|
||
on: | ||
push: | ||
branches: [ 'main' ] | ||
branches: [ main ] | ||
paths: | ||
- "**/*.md" | ||
- ".github/workflows/check-markdown.yml" | ||
- .github/workflows/check-markdown.yml | ||
pull_request: | ||
branches: [ 'main' ] | ||
branches: [ main ] | ||
|
||
jobs: | ||
lint: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
statuses: write | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Use Node.js | ||
uses: actions/setup-node@v3 | ||
- uses: bmazzarol/bmazzarol/.github/actions/check-markdown@main | ||
with: | ||
node-version: 16.x | ||
- name: Run Markdownlint | ||
run: | | ||
npm i | ||
npx markdownlint-cli2 "HttpBuildR*/**/*.md" "*.md" "!LICENSE.md" | ||
targetMdFiles: | | ||
"HttpBuildR*/**/*.md" "*.md" "!LICENSE.md" |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,81 +1,22 @@ | ||
name: CI Build | ||
|
||
on: | ||
push: | ||
branches: [ "main" ] | ||
branches: [ main ] | ||
pull_request: | ||
branches: [ "main" ] | ||
branches: [ main ] | ||
|
||
jobs: | ||
build: | ||
if: ${{ github.actor != 'dependabot[bot]' }} | ||
name: Build and analyze | ||
runs-on: ubuntu-latest | ||
permissions: | ||
checks: write | ||
pull-requests: write | ||
steps: | ||
- name: Setup .NET | ||
uses: actions/setup-dotnet@v3 | ||
- uses: bmazzarol/bmazzarol/.github/actions/ci-build@main | ||
with: | ||
dotnet-version: | | ||
6.0.x | ||
7.0.x | ||
- name: Set up JDK 17 | ||
uses: actions/setup-java@v3 | ||
with: | ||
java-version: 17 | ||
distribution: 'zulu' | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
- name: Cache SonarCloud packages | ||
uses: actions/cache@v3 | ||
with: | ||
path: ~\sonar\cache | ||
key: ${{ runner.os }}-sonar | ||
restore-keys: ${{ runner.os }}-sonar | ||
- name: Cache SonarCloud scanner | ||
id: cache-sonar-scanner | ||
uses: actions/cache@v3 | ||
with: | ||
path: .\.sonar\scanner | ||
key: ${{ runner.os }}-sonar-scanner | ||
restore-keys: ${{ runner.os }}-sonar-scanner | ||
- name: Install SonarCloud scanner | ||
if: steps.cache-sonar-scanner.outputs.cache-hit != 'true' | ||
shell: pwsh | ||
run: | | ||
New-Item -Path ./.sonar/scanner -ItemType Directory | ||
dotnet tool update dotnet-sonarscanner --tool-path ./.sonar/scanner | ||
dotnet tool install JetBrains.dotCover.GlobalTool | ||
- name: Build and analyze | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} | ||
shell: pwsh | ||
run: | | ||
./.sonar/scanner/dotnet-sonarscanner begin ` | ||
/k:"bmazzarol_Http-BuildR" ` | ||
/o:"bmazzarol" ` | ||
/d:sonar.token="${{ secrets.SONAR_TOKEN }}" ` | ||
/d:sonar.host.url="https://sonarcloud.io" ` | ||
/d:sonar.cs.dotcover.reportsPaths=dotCover.Output.html ` | ||
/d:sonar.cs.vstest.reportsPaths=**/test-results.trx | ||
dotnet dotcover test ` | ||
--dcReportType=HTML ` | ||
--dcAttributeFilters=System.Diagnostics.CodeAnalysis.ExcludeFromCodeCoverageAttribute ` | ||
--verbosity normal ` | ||
--logger "trx;LogFileName=test-results.trx" | ||
./.sonar/scanner/dotnet-sonarscanner end ` | ||
/d:sonar.token="${{ secrets.SONAR_TOKEN }}" | ||
- name: Upload Test Results | ||
uses: actions/upload-artifact@v2 | ||
if: ${{ always() && github.event_name == 'pull_request' }} | ||
with: | ||
name: test-results | ||
path: '**/test-results.trx' | ||
- name: Publish Test Results | ||
uses: EnricoMi/publish-unit-test-result-action@v2 | ||
if: ${{ always() && github.event_name == 'pull_request' }} | ||
with: | ||
files: | | ||
**/test-results.trx | ||
githubToken: ${{ secrets.GITHUB_TOKEN }} | ||
sonarToken: ${{ secrets.SONAR_TOKEN }} | ||
sonarProjectKey: bmazzarol_Http-BuildR |
This file was deleted.
Oops, something went wrong.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,18 @@ | ||
name: "Test Reporter" | ||
name: Test Reporter | ||
|
||
on: | ||
workflow_run: | ||
workflows: [ 'CI Build' ] | ||
types: [ 'completed' ] | ||
workflows: [ CI Build ] | ||
types: [ completed ] | ||
|
||
jobs: | ||
report: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: dorny/test-reporter@v1 | ||
with: | ||
artifact: 'test-results' | ||
name: 'Test Results' | ||
path: '**/test-results.trx' | ||
artifact: test-results | ||
name: Test Results | ||
path: | | ||
**/*.trx | ||
reporter: dotnet-trx |
Oops, something went wrong.