-
Notifications
You must be signed in to change notification settings - Fork 57
39 lines (37 loc) · 1.21 KB
/
release-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
33
34
35
36
37
38
39
name: Release
on:
push:
tags:
- "v*.*.*"
jobs:
release:
runs-on: "ubuntu-latest"
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
submodules: 'true'
- name: Import GPG key
uses: crazy-max/ghaction-import-gpg@v6.2.0
with:
gpg_private_key: "${{ secrets.GPG_PRIVATE_KEY }}"
passphrase: "${{ secrets.GPG_PASSPHRASE }}"
- name: "Archive zram-config"
run: |
export tag="${{ github.ref_name }}"
sudo apt-get install lzip
git ls-files --recurse-submodules | tar -cf zram-config-${tag}.tar --xform s:^:zram-config-${tag}/: --verbatim-files-from -T-
lzip --best --keep --verbose --verbose zram-config-${tag}.tar
gpg --detach-sign --armor zram-config-${tag}.tar.lz
gpg --verify zram-config-${tag}.tar.lz.asc zram-config-${tag}.tar.lz
unset tag
shell: bash
- uses: "softprops/action-gh-release@v2"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
generate_release_notes: true
make_latest: true
files: |
zram-config-*.tar.lz
zram-config-*.tar.lz.asc