-
Notifications
You must be signed in to change notification settings - Fork 29
38 lines (35 loc) · 1.06 KB
/
release.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
37
38
name: Corral Release
on:
release:
types: [published]
env:
SOLUTION: source/Corral.sln
jobs:
job0:
name: Corral Release
runs-on: ubuntu-20.04
steps:
- name: Setup dotnet
uses: actions/setup-dotnet@v1
with:
dotnet-version: '6.0.x'
- name: Checkout Corral
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Build Corral, package Corral
run: |
# Find version from tag info
VERSION="${GITHUB_REF##*/v}"
echo VERSION=$VERSION
# Change directory to Corral root folder
cd $GITHUB_WORKSPACE
# Restore dotnet tools
dotnet tool restore
# Build Corral
dotnet build -p:Version=$VERSION -c Release ${SOLUTION}
# Create packages
dotnet pack -p:Version=$VERSION --no-build -c Release ${SOLUTION}
- name: Deploy to nuget
run:
dotnet nuget push "source/Corral/bin/Release/Corral*.nupkg" -k ${{ secrets.NUGET_API_KEY }} -s https://api.nuget.org/v3/index.json