-
Notifications
You must be signed in to change notification settings - Fork 123
/
action.yml
32 lines (29 loc) · 962 Bytes
/
action.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
name: nuget
description: 'Publish NuGet packages'
inputs:
dotnet-version:
description: 'The dotnet framework and SDK version.'
default: 8.0.x
required: true
nuget-api-key:
description: 'The NuGet API key to publish artifacts'
default: 'nuget-api-key'
required: true
packages-directory:
description: 'The root directory of the NuGet packages that should be published'
server-url:
description: 'Specifies the NuGet server URL'
required: true
default: 'https://api.nuget.org/v3/index.json'
runs:
using: "composite"
steps:
- name: Setup dotnet environment
uses: actions/setup-dotnet@v3
id: setup
with:
dotnet-version: ${{ inputs.dotnet-version }}
- name: Publish to NuGet
working-directory: ${{ inputs.packages-directory }}
shell: bash
run: 'dotnet nuget push "*.nupkg" --skip-duplicate --api-key ${{ inputs.nuget-api-key }} --source ${{ inputs.server-url }}'