-
Notifications
You must be signed in to change notification settings - Fork 11
77 lines (68 loc) · 2.02 KB
/
release.yaml
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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
name: release nightly
on:
workflow_run:
workflows:
- build
types:
- completed
branches:
- master
env:
SK_VERSION: nover
jobs:
release:
runs-on: ubuntu-latest
if: ${{ github.event.workflow_run.conclusion == 'success' }}
steps:
- name: Download artifacts
uses: dawidd6/action-download-artifact@v3
with:
workflow: cmake.yml
branch: ${{ github.event.release.target_commitish }}
workflow_conclusion: success
- name: Import signature key
uses: crazy-max/ghaction-import-gpg@v6
with:
gpg_private_key: ${{ secrets.GHA_GPG_KEY }}
passphrase: ${{ secrets.GHA_GPG_PWD }}
- name: Move artifacts to workspace
run: |
for file in *; do
if [ -d $file ]; then
pushd $file
if [[ $file == *-win64 ]]; then
7z a ../$file.7z .
gpg --detach-sign ../$file.7z
# 7z a ../$file-modulesonly.7z '-ir!*.spk' '-ir!revil*.dll'
# gpg --detach-sign ../$file-modulesonly.7z
else
BASENAME=$(basename *.tar.xz .tar.xz)
echo "SK_VERSION=$(echo ${BASENAME} | cut -d'-' -f 2)" >> $GITHUB_ENV
# tar -xf *.tar.xz
# 7z a ../${BASENAME}-modulesonly.7z '-ir!*.spk' '-ir!librevil.so*'
# gpg --detach-sign ../${BASENAME}-modulesonly.7z
mv *.tar.xz ..
gpg --detach-sign ../*.tar.xz
fi
popd
fi
done
- uses: actions/checkout@v4
with:
path: repo
- name: Delete release
working-directory: repo
run: gh release delete nightly --cleanup-tag
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Wait a sec
run: sleep 2
- name: Release them
uses: softprops/action-gh-release@v2
with:
files: |
*.xz
*.7z
*.sig
tag_name: nightly
name: RevilToolset ${{env.SK_VERSION}} (nightly)