Skip to content

Commit 6651a87

Browse files
committed
Build binary artifacts on tag push rather than release
1 parent 30e334a commit 6651a87

File tree

2 files changed

+39
-31
lines changed

2 files changed

+39
-31
lines changed

.github/workflows/artifacts.yml

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
name: Build binary artifacts
2+
3+
on:
4+
push:
5+
tags:
6+
- "v*"
7+
8+
jobs:
9+
binaries:
10+
11+
strategy:
12+
matrix:
13+
os: [ ubuntu-latest, macos-latest ] # windows-latest,
14+
15+
runs-on: ${{ matrix.os }}
16+
17+
steps:
18+
- uses: actions/checkout@v2
19+
with:
20+
submodules: recursive
21+
- name: Set up Python
22+
uses: actions/setup-python@v1
23+
with:
24+
python-version: '3.x'
25+
- name: Install dependencies
26+
run: |
27+
python -m pip install --upgrade pip
28+
pip install setuptools pyinstaller
29+
pip install .
30+
- name: Build the binary
31+
run: |
32+
make -C bindist
33+
cd bindist && echo "DIST_FILE=`make dist-name | tr -d '\n'`" >> $GITHUB_ENV
34+
- name: Release binary artifacts
35+
if: |
36+
github.event.release
37+
uses: softprops/action-gh-release@v0.1.14
38+
with:
39+
file: bindist/${{ env.DIST_FILE }}

.github/workflows/pythonpublish.yml

Lines changed: 0 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -8,37 +8,6 @@ on:
88
types: [published]
99

1010
jobs:
11-
binaries:
12-
13-
strategy:
14-
matrix:
15-
os: [ ubuntu-latest, macos-latest ] # windows-latest,
16-
17-
runs-on: ${{ matrix.os }}
18-
19-
steps:
20-
- uses: actions/checkout@v2
21-
with:
22-
submodules: recursive
23-
- name: Set up Python
24-
uses: actions/setup-python@v1
25-
with:
26-
python-version: '3.x'
27-
- name: Install dependencies
28-
run: |
29-
python -m pip install --upgrade pip
30-
pip install setuptools pyinstaller
31-
pip install .
32-
- name: Build the binary
33-
run: |
34-
make -C bindist
35-
cd bindist && echo "DIST_FILE=`make dist-name | tr -d '\n'`" >> $GITHUB_ENV
36-
- name: Release binary artifacts
37-
if: |
38-
github.event.release
39-
uses: softprops/action-gh-release@v0.1.14
40-
with:
41-
file: bindist/${{ env.DIST_FILE }}
4211

4312
deploy:
4413

0 commit comments

Comments
 (0)