forked from pytorch/test-infra
-
Notifications
You must be signed in to change notification settings - Fork 0
49 lines (40 loc) · 1.41 KB
/
Copy pathblast-release.yml
File metadata and controls
49 lines (40 loc) · 1.41 KB
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
name: Blast CLI Release
on:
workflow_dispatch:
permissions:
contents: write
jobs:
build-and-release:
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Setup Python 3.11
uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5.6.0
with:
python-version: "3.11"
- name: Install build tools
run: pip install build==1.2.2
- name: Build wheel
run: |
cd tools/remote_execution/blast
python -m build --wheel
- name: Get version from wheel
id: version
run: |
WHEEL=$(ls tools/remote_execution/blast/dist/*.whl)
VERSION=$(echo "$WHEEL" | grep -oP '\d+\.\d+\.\d+')
echo "version=$VERSION" >> "$GITHUB_OUTPUT"
echo "Built version: $VERSION"
- name: Smoke test
run: |
pip install tools/remote_execution/blast/dist/*.whl
blast --help
- name: Create tag and release
uses: softprops/action-gh-release@c95fe1489396fe8a9eb87c0abf8aa5b2ef267fda # v2.2.1
with:
tag_name: blast-cli-v${{ steps.version.outputs.version }}
name: Blast CLI v${{ steps.version.outputs.version }}
files: tools/remote_execution/blast/dist/*.whl
body: |
blast-cli==${{ steps.version.outputs.version }}