Mingor(100757) 762803ac0a
Some checks failed
dotnet-publish-nuget / Pack-And-Publish (push) Failing after 3s
update actions yaml
2024-08-27 17:22:59 +08:00

28 lines
855 B
YAML

name: dotnet-publish-nuget
on: [push]
jobs:
Pack-And-Publish:
runs-on: ubuntu-latest
steps:
- name: Setup .NET Core
uses: actions/setup-dotnet@v1
with:
dotnet-version: 8.x
cache: true
source-url: https://git.mworkspace.cn/api/packages/GiteaActionsSample/nuget/index.json
env:
NUGET_AUTH_TOKEN: ${{secrets.NUGET_APIKEY}}
- name: List files in the repos
uses: actions/checkout@v3
run: ls ${{ gitea.workspace }} && ls $GITEA_WORKSPACE
- name: Install dependencies
run: dotnet restore
- name: Build
run: dotnet build --configuration Release --no-restore
- name: Test
run: dotnet test --no-restore --verbosity normal
- name: Pack
run: dotnet pack -c Release --no-restore
- name: Publish
run: dotnet nuget push bin/Release/*.nupkg