Skip to content

fix(cache): deduplicate results #12

fix(cache): deduplicate results

fix(cache): deduplicate results #12

Workflow file for this run

name: Publish .NET Package
on:
push:
pull_request:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Setup .NET
uses: actions/setup-dotnet@v3
with:
dotnet-version: '8.0.x' # Change this to the .NET version you are using
- name: Restore dependencies
run: dotnet restore
- name: Write Strong Name Key
env:
KEY: ${{ secrets.STRONG_NAME_KEY }}
run: echo "$KEY" | base64 --decode > Topgg.ProxyCheck/topgg.proxycheck.snk
- name: Build
run: dotnet build --configuration Release --no-restore
- name: Test
run: dotnet test --no-restore --verbosity normal
- name: Publish
run: dotnet pack --configuration Release --no-build --output ./artifacts
if: github.ref == 'refs/heads/master'
- name: Push to GitHub Packages
run: dotnet nuget push ./artifacts/*.nupkg -k ${{ secrets.GITHUB_TOKEN }} -s https://nuget.pkg.github.com/top-gg/index.json --skip-duplicate
if: github.ref == 'refs/heads/master'
- name: Push to Nuget
run: dotnet nuget push ./artifacts/*.nupkg -k ${{ secrets.NUGET_TOKEN }} -s https://api.nuget.org/v3/index.json --skip-duplicate
env:
DOTNET_NOLOGO: true
DOTNET_CLI_TELEMETRY_OPTOUT: true