forked from veldrid/veldrid
-
Notifications
You must be signed in to change notification settings - Fork 5
36 lines (33 loc) · 997 Bytes
/
dotnet.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
name: Veldrid CI build
on:
create: # when tags are created
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
build_windows:
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 8.0.x
- name: Restore dependencies
run: dotnet restore src
- name: Build
run: dotnet build --no-restore src -c Release
- name: Build Packages
run: dotnet pack src -c Release
- name: Publish tagged release to nuget.org
if: startsWith(github.ref, 'refs/tags/')
run: dotnet nuget push bin\Packages\Release\ppy.*.nupkg -s https://api.nuget.org/v3/index.json --api-key ${{secrets.NUGET_API_KEY}}
- name: Generate GitHub Release
if: startsWith(github.ref, 'refs/tags/')
uses: softprops/action-gh-release@v2
with:
files: |
bin\Packages\Release\ppy.*.nupkg