-
Notifications
You must be signed in to change notification settings - Fork 2
54 lines (42 loc) · 1.11 KB
/
release.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
51
52
53
name: Build and Publish
on:
push:
branches:
- release
jobs:
release:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.12'
- name: Upgrade pip
run: |
pip install pip
pip --version
- name: Install Poetry
run: |
pip install poetry
poetry --version
- name: Install dependencies
run: poetry install --no-interaction
- name: Build wheel
run: poetry build
- name: Run Tests
run: poetry run pytest
- name: Generate release tag
id: tag
run: |
echo "::set-output name=release_tag::$(git rev-parse HEAD | head -c 8)"
- name: Upload Release Asset
uses: softprops/action-gh-release@v2
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ steps.tag.outputs.release_tag }}
files: dist/*.whl
draft: false
prerelease: false