Skip to content

Commit 6b99b7e

Browse files
committed
Always build packages and upload their artifacts.
1 parent f4005f2 commit 6b99b7e

File tree

1 file changed

+38
-3
lines changed

1 file changed

+38
-3
lines changed

.github/workflows/build_release.yml

Lines changed: 38 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,24 @@
11
name: Build Source Release
22

3-
# Trigger whenever a release is created
43
on:
4+
push:
5+
paths-ignore:
6+
- ".gitignore"
7+
- "docs/**"
8+
- "ChangeLog"
9+
- "CREDITS.TXT"
10+
- "COMPILE_MAKE.TXT"
11+
- "BUILDING.md"
12+
- "CONTRIBUTING.md"
13+
- "LICENSE.TXT"
14+
- "LICENSE_LLVM.TXT"
15+
- "README.md"
16+
- "RELEASE_NOTES"
17+
- "SPONSORS.TXT"
18+
- "TODO"
19+
pull_request:
520
release:
6-
types:
7-
- created
21+
types: [published]
822

923
jobs:
1024
build:
@@ -29,8 +43,15 @@ jobs:
2943
echo "tarball=$TARBALL" >> $GITHUB_OUTPUT
3044
echo "shasum=$SHASUM" >> $GITHUB_OUTPUT
3145
46+
- uses: actions/upload-artifact@v4
47+
with:
48+
path: |
49+
${{ steps.archive.outputs.tarball }}
50+
${{ steps.archive.outputs.shasum }}
51+
3252
- name: Upload tarball and shasum to release
3353
uses: softprops/action-gh-release@v2
54+
if: startsWith(github.ref, 'refs/tags') && github.event_name == 'release'
3455
env:
3556
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
3657
with:
@@ -54,8 +75,17 @@ jobs:
5475
cpack -G DEB
5576
cpack -G RPM
5677
78+
- uses: actions/upload-artifact@v4
79+
with:
80+
path: build/*.deb
81+
82+
- uses: actions/upload-artifact@v4
83+
with:
84+
path: build/*.rpm
85+
5786
- name: Upload debian package to release
5887
uses: softprops/action-gh-release@v2
88+
if: startsWith(github.ref, 'refs/tags') && github.event_name == 'release'
5989
env:
6090
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
6191
with:
@@ -102,8 +132,13 @@ jobs:
102132
cd build
103133
cpack -G NSIS
104134
135+
- uses: actions/upload-artifact@v4
136+
with:
137+
path: ./build/*.exe
138+
105139
- name: Upload NSIS installer to release
106140
uses: softprops/action-gh-release@v2
141+
if: startsWith(github.ref, 'refs/tags') && github.event_name == 'release'
107142
env:
108143
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
109144
with:

0 commit comments

Comments
 (0)