-
Notifications
You must be signed in to change notification settings - Fork 0
32 lines (31 loc) · 1013 Bytes
/
publish_annotations.yml
File metadata and controls
32 lines (31 loc) · 1013 Bytes
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
name: Publish Hexarc.Annotations Package
on:
workflow_dispatch:
inputs:
git-ref:
description: Get Ref (Optional)
required: false
jobs:
build_and_deploy:
runs-on: ubuntu-latest
defaults:
run:
working-directory: .
steps:
- uses: actions/setup-dotnet@v1
with:
dotnet-version: '6.0.x'
- name: Clone Repository (Latest)
uses: actions/checkout@v2
if: github.event.inputs.git-ref == ''
- name: Clone Repository (Custom Ref)
uses: actions/checkout@v2
if: github.event.inputs.git-ref != ''
with:
ref: ${{ github.event.inputs.git-ref }}
- name: Pack package
run: |
dotnet pack Hexarc.Annotations/Hexarc.Annotations.csproj --output packages --configuration Release
- name: Publish packages
run: |
dotnet nuget push packages/*.nupkg --source https://api.nuget.org/v3/index.json --api-key ${{ secrets.NUGET_API_KEY }} --skip-duplicate