-
Notifications
You must be signed in to change notification settings - Fork 2
38 lines (29 loc) · 1.15 KB
/
prerelease.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
name: '🧪 PRE-release'
on:
workflow_dispatch:
jobs:
release:
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/master'
steps:
- name: 🆔 Get latest run ID
id: runid
run: |
run_id=$(curl --request GET \
--url https://api.github.com/repos/${{ github.repository }}/actions/workflows/build.yml/runs \
--header 'authorization: Bearer ${{ secrets.GITHUB_TOKEN }}' \
| jq '.workflow_runs[] | select(.status=="completed") | .id' | head -1)
echo "::set-output name=run-id::$run_id"
- name: ⬇️ Download binary output from build.yml
uses: actions/download-artifact@v4
with:
name: managed
path: .
github-token: ${{ secrets.GITHUB_TOKEN }}
run-id: ${{ steps.runid.outputs.run-id }}
- name: debug
run: ls -R
- name: list release notes
run: cat docs/version-notes.md
- name: 📦 Publish to NuGet
run: dotnet nuget push managed/IronCompress/bin/Release/*.nupkg --api-key ${{ secrets.NUGET_API_KEY }} --source https://api.nuget.org/v3/index.json --skip-duplicate