Skip to content

Commit 1b15bf1

Browse files
committed
feat: add pypi release
1 parent 94bd694 commit 1b15bf1

File tree

1 file changed

+42
-0
lines changed

1 file changed

+42
-0
lines changed
Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
name: Release
2+
'on':
3+
workflow_call:
4+
secrets:
5+
PYPI_TOKEN:
6+
required: true
7+
jobs:
8+
release:
9+
name: Release
10+
runs-on: ubuntu-latest
11+
steps:
12+
- name: Check out repository
13+
uses: actions/checkout@v5
14+
with:
15+
fetch-depth: 0
16+
17+
- name: Set up Python 3.x
18+
uses: actions/setup-python@v6
19+
with:
20+
python-version: '3.x'
21+
22+
- name: Install poetry
23+
run: pip3 install --disable-pip-version-check poetry
24+
25+
- name: Set up Node.js
26+
uses: actions/setup-node@v5
27+
with:
28+
node-version: 'lts/*'
29+
30+
- name: Install semantic-release
31+
run: |
32+
npm install --global semantic-release @semantic-release/exec conventional-changelog-conventionalcommits
33+
34+
# - name: Configure semantic-release
35+
# run: |
36+
# echo '{"preset":"conventionalcommits","plugins":[["@semantic-release/commit-analyzer"],["@semantic-release/release-notes-generator"],["@semantic-release/github"],["@semantic-release/exec",{"publishCmd":"ansible-galaxy role import --api-key ${{ secrets.ANSIBLE_GALAXY_API_TOKEN }} $(echo ${{ github.repository }} | cut -d/ -f1) $(echo ${{ github.repository }} | cut -d/ -f2)"}]]}' > .releaserc.json
37+
38+
# - name: Run semantic-release
39+
# env:
40+
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
41+
# run: |
42+
# semantic-release

0 commit comments

Comments
 (0)