-
Notifications
You must be signed in to change notification settings - Fork 2
47 lines (44 loc) · 1.1 KB
/
python-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
name: Master Deploy
on:
push:
branches:
- "master"
permissions:
contents: write
jobs:
deploy:
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v3
with:
python-version: "3.11"
- name: Install Task
uses: arduino/setup-task@v2
with:
version: 3.37.1
- name: Install dependencies and test
run: |
task setup
venv/bin/poetry run pre-commit uninstall
task test
- name: Generate Documentation
run: |
task docs
- name: Version Bump
run: |
task bump
git push
git push origin v$(task version)
- name: Build package and publish
env:
PYPI_KEY: ${{ secrets.PYPI_KEY }}
run: |
task publish
- name: Publish Release
env:
GH_TOKEN: ${{ github.token }}
REPO_NAME: ${{ github.repository }}
TAG: $(task version)
run: gh release create "$TAG" --repo="$REPO_NAME" --title="$TAG" --generate-notes