-
Notifications
You must be signed in to change notification settings - Fork 0
41 lines (30 loc) · 1.19 KB
/
dotnet_main.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
# This workflow will build a .NET project
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-net
name: Main-Branch-Flow
on:
push:
branches: [ "main" ]
env:
PROJECT_PATH: 'source/WebNativeDEV.SINUS.Core/WebNativeDEV.SINUS.Core.csproj'
PACK_OUT_PATH: ${{ github.workspace }}\output
jobs:
build:
name: Build
runs-on: windows-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup .NET
uses: actions/setup-dotnet@v3
with:
dotnet-version: 7.0.x
- name: Restore dependencies
run: dotnet restore ${{ env.PROJECT_PATH }}
- name: Build
run: dotnet build ${{ env.PROJECT_PATH }} --no-restore --configuration Release
# - name: Test
# run: dotnet test --no-build --verbosity normal
- name: Pack
run: dotnet pack ${{ env.PROJECT_PATH }} --no-restore --no-build --configuration Release --include-symbols --output ${{ env.PACK_OUT_PATH }}
- name: Publish nuget
run: dotnet nuget push ${{ env.PACK_OUT_PATH }}\*.symbols.nupkg --api-key ${{ secrets.NUGET_AUTH_TOKEN }} --source https://api.nuget.org/v3/index.json