diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 5dfa3a6..fa8c583 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -1,15 +1,57 @@ version: 2 updates: -- package-ecosystem: "github-actions" - directory: "/" - schedule: - interval: daily - time: "01:00" - open-pull-requests-limit: 10 + - package-ecosystem: "github-actions" + directory: "/" + schedule: + interval: daily + time: "01:00" + timezone: "America/Chicago" + open-pull-requests-limit: 10 -- package-ecosystem: nuget - directory: "/" - schedule: - interval: daily - time: "02:00" - open-pull-requests-limit: 10 + - package-ecosystem: nuget + directory: "/" + schedule: + interval: daily + time: "02:00" + timezone: "America/Chicago" + open-pull-requests-limit: 10 + groups: + Azure: + patterns: + - "Azure.*" + - "Microsoft.Azure.*" + - "Microsoft.Extensions.Azure" + AspNetCoreHealthChecks: + patterns: + - "AspNetCore.HealthChecks.*" + AspNetCore: + patterns: + - "Microsoft.AspNetCore.*" + - "Microsoft.Extensions.Features" + MicrosoftExtensions: + patterns: + - "Microsoft.Extensions.*" + EntityFrameworkCore: + patterns: + - "Microsoft.EntityFrameworkCore.*" + OpenTelemetry: + patterns: + - "OpenTelemetry.*" + Serilog: + patterns: + - "Serilog" + - "Serilog.*" + Hangfire: + patterns: + - "Hangfire" + - "Hangfire.*" + Testcontainers: + patterns: + - "Testcontainers.*" + xUnit: + patterns: + - "xunit" + - "xunit.assert" + - "xunit.core" + - "xunit.extensibility.*" + - "xunit.runner.*" diff --git a/.github/workflows/dotnet.yml b/.github/workflows/dotnet.yml index d5c0e45..2a09c88 100644 --- a/.github/workflows/dotnet.yml +++ b/.github/workflows/dotnet.yml @@ -3,7 +3,7 @@ name: Build env: DOTNET_NOLOGO: true DOTNET_SKIP_FIRST_TIME_EXPERIENCE: true - BUILD_PATH: '${{github.workspace}}/artifacts' + BUILD_PATH: "${{github.workspace}}/artifacts" COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }} on: @@ -12,58 +12,56 @@ on: - master - develop tags: - - 'v*' + - "v*" pull_request: branches: - master - develop jobs: - build: runs-on: ubuntu-latest steps: - - name: Checkout - uses: actions/checkout@v4 - with: - fetch-depth: 0 - - - name: Install .NET Core - uses: actions/setup-dotnet@v4 - with: + - name: Checkout + uses: actions/checkout@v4 + with: + fetch-depth: 0 + + - name: Install .NET + uses: actions/setup-dotnet@v4 + with: dotnet-version: | - 6.0.x - 7.0.x - 8.0.x - - - name: Restore Dependencies - run: dotnet restore + 6.0.x + 7.0.x + 8.0.x - - name: Build Solution - run: dotnet build --no-restore --configuration Release + - name: Restore Dependencies + run: dotnet restore - - name: Run Test - run: dotnet test --no-build --configuration Release --collect:"XPlat Code Coverage" --settings coverlet.runsettings + - name: Build Solution + run: dotnet build --no-restore --configuration Release + - name: Run Test + run: dotnet test --no-build --configuration Release --collect:"XPlat Code Coverage" --settings coverlet.runsettings - - name: Report Coverage - if: success() - uses: coverallsapp/github-action@v2 - with: + - name: Report Coverage + if: success() + uses: coverallsapp/github-action@v2 + with: file: "${{github.workspace}}/test/*/TestResults/*/coverage.info" format: lcov - - name: Create Packages - if: success() && github.event_name != 'pull_request' - run: dotnet pack --configuration Release --include-symbols --include-source --no-build --output "${{env.BUILD_PATH}}" + - name: Create Packages + if: success() && github.event_name != 'pull_request' + run: dotnet pack --configuration Release --no-build --output "${{env.BUILD_PATH}}" - - name: Upload Packages - if: success() && github.event_name != 'pull_request' - uses: actions/upload-artifact@v4 - with: - name: packages - path: '${{env.BUILD_PATH}}' + - name: Upload Packages + if: success() && github.event_name != 'pull_request' + uses: actions/upload-artifact@v4 + with: + name: packages + path: "${{env.BUILD_PATH}}" deploy: runs-on: ubuntu-latest @@ -71,30 +69,29 @@ jobs: if: success() && github.event_name != 'pull_request' && (github.ref == 'refs/heads/master' || startsWith(github.ref, 'refs/tags/v')) steps: - - name: Download Artifact - uses: actions/download-artifact@v4 - with: - name: packages - - - name: Publish Packages GitHub - run: | - for package in $(find -name "*.nupkg"); do - echo "${0##*/}": Pushing $package... - dotnet nuget push $package --source https://nuget.pkg.github.com/loresoft/index.json --api-key ${{ secrets.GITHUB_TOKEN }} --skip-duplicate - done - - - name: Publish Packages feedz - run: | - for package in $(find -name "*.nupkg"); do - echo "${0##*/}": Pushing $package... - dotnet nuget push $package --source https://f.feedz.io/loresoft/open/nuget/index.json --api-key ${{ secrets.FEEDDZ_KEY }} --skip-duplicate - done - - - name: Publish Packages Nuget - if: startsWith(github.ref, 'refs/tags/v') - run: | - for package in $(find -name "*.nupkg"); do - echo "${0##*/}": Pushing $package... - dotnet nuget push $package --source https://api.nuget.org/v3/index.json --api-key ${{ secrets.NUGET_KEY }} --skip-duplicate - done - + - name: Download Artifact + uses: actions/download-artifact@v4 + with: + name: packages + + - name: Publish Packages GitHub + run: | + for package in $(find -name "*.nupkg"); do + echo "${0##*/}": Pushing $package... + dotnet nuget push $package --source https://nuget.pkg.github.com/loresoft/index.json --api-key ${{ secrets.GITHUB_TOKEN }} --skip-duplicate + done + + - name: Publish Packages feedz + run: | + for package in $(find -name "*.nupkg"); do + echo "${0##*/}": Pushing $package... + dotnet nuget push $package --source https://f.feedz.io/loresoft/open/nuget/index.json --api-key ${{ secrets.FEEDDZ_KEY }} --skip-duplicate + done + + - name: Publish Packages Nuget + if: startsWith(github.ref, 'refs/tags/v') + run: | + for package in $(find -name "*.nupkg"); do + echo "${0##*/}": Pushing $package... + dotnet nuget push $package --source https://api.nuget.org/v3/index.json --api-key ${{ secrets.NUGET_KEY }} --skip-duplicate + done diff --git a/coverlet.runsettings b/coverlet.runsettings index 4eac22c..b28750f 100644 --- a/coverlet.runsettings +++ b/coverlet.runsettings @@ -5,8 +5,6 @@ lcov - Obsolete,GeneratedCodeAttribute,CompilerGeneratedAttribute,TestSDKAutoGeneratedCode - true diff --git a/src/Directory.Build.props b/src/Directory.Build.props index 9955ddc..330c692 100644 --- a/src/Directory.Build.props +++ b/src/Directory.Build.props @@ -16,14 +16,18 @@ true - - portable - true - true - snupkg + + embedded + true + false - + + true + + + + en-US latest enable 1591 @@ -32,9 +36,8 @@ v - + - diff --git a/src/FluentRest.Factory/FluentRest.Factory.csproj b/src/FluentRest.Factory/FluentRest.Factory.csproj index d120b9a..6afc90a 100644 --- a/src/FluentRest.Factory/FluentRest.Factory.csproj +++ b/src/FluentRest.Factory/FluentRest.Factory.csproj @@ -8,7 +8,7 @@ - + diff --git a/src/FluentRest.Fake/FluentRest.Fake.csproj b/src/FluentRest.Fake/FluentRest.Fake.csproj index a0750c7..b504a22 100644 --- a/src/FluentRest.Fake/FluentRest.Fake.csproj +++ b/src/FluentRest.Fake/FluentRest.Fake.csproj @@ -1,11 +1,10 @@ - + netstandard2.0;netstandard2.1;net6.0;net7.0;net8.0 - - + diff --git a/src/FluentRest/FluentRest.csproj b/src/FluentRest/FluentRest.csproj index a0750c7..b504a22 100644 --- a/src/FluentRest/FluentRest.csproj +++ b/src/FluentRest/FluentRest.csproj @@ -1,11 +1,10 @@ - + netstandard2.0;netstandard2.1;net6.0;net7.0;net8.0 - - + diff --git a/test/FluentRest.Factory.Tests/FluentRest.Factory.Tests.csproj b/test/FluentRest.Factory.Tests/FluentRest.Factory.Tests.csproj index a2605be..072058a 100644 --- a/test/FluentRest.Factory.Tests/FluentRest.Factory.Tests.csproj +++ b/test/FluentRest.Factory.Tests/FluentRest.Factory.Tests.csproj @@ -10,16 +10,16 @@ - + all runtime; build; native; contentfiles; analyzers; buildtransitive - + all runtime; build; native; contentfiles; analyzers - + diff --git a/test/FluentRest.Fake.Tests/FluentRest.Fake.Tests.csproj b/test/FluentRest.Fake.Tests/FluentRest.Fake.Tests.csproj index e9b4024..473734b 100644 --- a/test/FluentRest.Fake.Tests/FluentRest.Fake.Tests.csproj +++ b/test/FluentRest.Fake.Tests/FluentRest.Fake.Tests.csproj @@ -11,16 +11,16 @@ - + all runtime; build; native; contentfiles; analyzers; buildtransitive - + all runtime; build; native; contentfiles; analyzers - + diff --git a/test/FluentRest.Tests/FluentRest.Tests.csproj b/test/FluentRest.Tests/FluentRest.Tests.csproj index 149ee6d..de570fe 100644 --- a/test/FluentRest.Tests/FluentRest.Tests.csproj +++ b/test/FluentRest.Tests/FluentRest.Tests.csproj @@ -7,18 +7,18 @@ - + all runtime; build; native; contentfiles; analyzers; buildtransitive - + all runtime; build; native; contentfiles; analyzers - + diff --git a/test/FluentRest.Tests/GitHub/Models/Issue.cs b/test/FluentRest.Tests/GitHub/Models/Issue.cs index a4a7cc4..a2e3fe3 100644 --- a/test/FluentRest.Tests/GitHub/Models/Issue.cs +++ b/test/FluentRest.Tests/GitHub/Models/Issue.cs @@ -22,7 +22,7 @@ public class Issue public string HtmlUrl { get; set; } [JsonPropertyName("id")] - public int Id { get; set; } + public long Id { get; set; } [JsonPropertyName("number")] public int Number { get; set; }