-
Notifications
You must be signed in to change notification settings - Fork 0
62 lines (62 loc) · 1.8 KB
/
publish_development.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
54
55
56
57
58
59
60
61
62
---
name: Publish development packages
on:
push:
branches:
- main
paths:
- cpp/**/include/**
- cpp/**/src/**
- '**/*.pxd'
- '**/*.pyx'
- python/**/mlrl/**
jobs:
update_development_version:
name: Update development version
if: "!contains(github.event.head_commit.message, '[Bot]')"
runs-on: ubuntu-latest
steps:
- name: Generate token
uses: actions/create-github-app-token@v1
id: app-token
with:
app-id: ${{ secrets.TOKEN_APP_ID }}
private-key: ${{ secrets.TOKEN_APP_SECRET }}
- name: Checkout
uses: actions/checkout@v4
with:
token: ${{ steps.app-token.outputs.token }}
- name: Setup git
uses: fregante/setup-git-user@v2
- name: Update development version
run: |
./build increment_development_version
git add .version-dev
git commit -m "[Bot] Update development version to $(cat .version-dev)."
git push
read_python_version:
name: Read Python version
runs-on: ubuntu-latest
outputs:
python_version: ${{ steps.python_version.outputs.content }}
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Read Python version
uses: juliangruber/read-file-action@v1
id: python_version
with:
path: .version-python
publish_packages:
name: Publish wheel packages
needs:
- update_development_version
- read_python_version
uses: ./.github/workflows/template_publish.yml
with:
python_version: ${{ needs.read_python_version.outputs.python_version }}
pypi_repository: testpypi
dev_release: true
secrets:
pypi_username: ${{ secrets.TEST_PYPI_USERNAME }}
pypi_password: ${{ secrets.TEST_PYPI_PASSWORD }}