-
Notifications
You must be signed in to change notification settings - Fork 0
50 lines (43 loc) · 1.13 KB
/
publish.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
name: publish
on:
release:
types:
- created
permissions:
contents: write
actions: write
jobs:
publish:
name: Publish for ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
include:
- os: ubuntu-latest
artifact_name: wrk
asset_name: wrk-linux-amd64
- os: macos-latest
artifact_name: wrk
asset_name: wrk-macos-amd64
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0
- name: build executable
run: make target/wrk
- name: build python package
run: |
pip install build
cd python
python -m build
- name: Upload python package to PYPI
uses: pypa/[email protected]
with:
password: ${{ secrets.PYPI_API_TOKEN }}
- name: Upload binaries to release
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: target/${{ matrix.artifact_name }}
asset_name: ${{ matrix.asset_name }}
tag: ${{ github.ref }}