-
Notifications
You must be signed in to change notification settings - Fork 1
46 lines (35 loc) · 1.25 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
39
40
41
42
43
44
45
46
name: Release
on:
workflow_dispatch:
inputs:
packageVersion:
description: 'Package version'
required: true
defaults:
run:
working-directory: src
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4
- name: Setup .NET SDK
uses: actions/setup-dotnet@6bd8b7f7774af54e05809fcc5431931b3eb1ddee # v4.0.1
- name: Install dependencies
run: dotnet restore
- name: Build
run: dotnet build -c Release --no-restore
- name: Test
run: dotnet test --no-restore -v normal -c Release --results-directory test-results -l trx
- name: Upload Test Results
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
if: always()
with:
name: test-results
path: src/test-results/*
- name: Pack
env:
PACKAGE_VERSION: ${{ github.event.inputs.packageVersion }}
run: dotnet pack -c Release -p:Version=$PACKAGE_VERSION Valleysoft.DockerfileModel
- name: Publish Package
run: dotnet nuget push "Valleysoft.DockerfileModel/bin/Release/*.nupkg" -k ${{secrets.NUGET_ORG_API_KEY}} -s https://nuget.org