-
Notifications
You must be signed in to change notification settings - Fork 7
52 lines (46 loc) · 1.82 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
47
48
49
50
51
name: Upload Asset
on:
push:
tags:
- '**'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Create tarball
run: |
tar cvzf sensu-windows-powershell-checks.tar.gz bin README.md LICENSE
- name: Create checksum
run: |
sha512sum sensu-windows-powershell-checks.tar.gz > sha512-checksums.txt
- name: Get Release
id: get_release
uses: bruceadams/[email protected]
- name: Upload Release Tarball
id: upload-release-tarball
uses: actions/upload-release-asset@v1
with:
upload_url: ${{ steps.get_release.outputs.upload_url }}
# This pulls from the Get Release step above,
# referencing it's ID to get its outputs object, which include a `upload_url`.
# See this blog post for more info:
# https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
asset_path: ./sensu-windows-powershell-checks.tar.gz
asset_name: sensu-windows-powershell-checks.tar.gz
asset_content_type: application/gzip
- name: Upload Release Checksums
id: upload-release-checksums
uses: actions/upload-release-asset@v1
with:
upload_url: ${{ steps.get_release.outputs.upload_url }}
# This pulls from the Get Release step above,
# referencing it's ID to get its outputs object, which include a `upload_url`.
# See this blog post for more info:
# https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
asset_path: ./sha512-checksums.txt
asset_name: sha512-checksums.txt
asset_content_type: text/plain