Skip to content

Commit 6167541

Browse files
committed
ci: use PyPi trusted publishing
1 parent 018036e commit 6167541

4 files changed

Lines changed: 45 additions & 19 deletions

File tree

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ jobs:
1010
max-parallel: 4
1111
matrix:
1212
os: [ubuntu-latest, windows-latest]
13-
python-version: ["3.9", "3.10", "3.11", "3.12"]
13+
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
1414
steps:
1515
- uses: actions/checkout@v4
1616
- name: Set up Python ${{ matrix.python-version }}

.github/workflows/publish.yml

Lines changed: 41 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -5,21 +5,46 @@ on:
55
- '*.*.*'
66
workflow_dispatch:
77
jobs:
8-
build-and-publish:
9-
name: Build and publish Kanboard's Python package
8+
build:
9+
name: Build distribution package
1010
runs-on: ubuntu-latest
1111
steps:
12-
- uses: actions/checkout@v4
13-
- uses: actions/setup-python@v5
14-
with:
15-
python-version: '3.x'
16-
- name: Install pypa/build
17-
run: >-
18-
python -m pip install build --user
19-
- name: Build a binary wheel and a source tarball
20-
run: >-
21-
python -m build --sdist --wheel --outdir dist/ .
22-
- name: Publish to PyPI
23-
uses: pypa/gh-action-pypi-publish@release/v1
24-
with:
25-
password: ${{ secrets.PYPI_API_TOKEN }}
12+
- uses: actions/checkout@v4
13+
- name: Set up Python
14+
uses: actions/setup-python@v5
15+
with:
16+
python-version: "3.x"
17+
- name: Install pypa/build
18+
run: >-
19+
python3 -m
20+
pip install
21+
build
22+
--user
23+
- name: Build a binary wheel and a source tarball
24+
run: python3 -m build
25+
- name: Store the distribution packages
26+
uses: actions/upload-artifact@v4
27+
with:
28+
name: python-package-distributions
29+
path: dist/
30+
31+
publish-to-pypi:
32+
name: Publish to PyPI
33+
if: startsWith(github.ref, 'refs/tags/') # only publish to PyPI on tag pushes
34+
needs:
35+
- build
36+
runs-on: ubuntu-latest
37+
environment:
38+
name: pypi
39+
url: https://pypi.org/p/kanboard
40+
permissions:
41+
id-token: write # IMPORTANT: mandatory for trusted publishing
42+
43+
steps:
44+
- name: Download all the dists
45+
uses: actions/download-artifact@v4
46+
with:
47+
name: python-package-distributions
48+
path: dist/
49+
- name: Publish distribution 📦 to PyPI
50+
uses: pypa/gh-action-pypi-publish@release/v1

README.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ Installation
1515
python3 -m pip install kanboard
1616
1717
18-
This library is compatible with Python >= 3.5.
18+
This library is compatible with Python >= 3.7.
1919

2020
Note: **Support for Python 2.7 has been dropped since version 1.1.0.**
2121

pyproject.toml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[project]
22
name = "kanboard"
3-
version = "1.1.5"
3+
version = "1.1.6"
44
description = "Client library for Kanboard"
55
readme = "README.rst"
66
requires-python = ">=3.7"
@@ -20,6 +20,7 @@ classifiers = [
2020
"Programming Language :: Python :: 3.10",
2121
"Programming Language :: Python :: 3.11",
2222
"Programming Language :: Python :: 3.12",
23+
"Programming Language :: Python :: 3.13",
2324
"Programming Language :: Python :: 3 :: Only",
2425
]
2526

0 commit comments

Comments
 (0)