Skip to content

Commit 98fc143

Browse files
committed
Add PyPI trusted publishing workflow
- Add GitHub Actions workflow for automated PyPI publishing - Update package name to OpenF1-python-client - Update author info and project URLs - Add funding link
1 parent 70d2b45 commit 98fc143

2 files changed

Lines changed: 59 additions & 8 deletions

File tree

.github/workflows/workflow.yml

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
name: Publish to PyPI
2+
3+
on:
4+
release:
5+
types: [published]
6+
workflow_dispatch:
7+
8+
jobs:
9+
build:
10+
name: Build distribution
11+
runs-on: ubuntu-latest
12+
13+
steps:
14+
- uses: actions/checkout@v4
15+
16+
- name: Set up Python
17+
uses: actions/setup-python@v5
18+
with:
19+
python-version: "3.12"
20+
21+
- name: Install build dependencies
22+
run: python -m pip install --upgrade pip build
23+
24+
- name: Build package
25+
run: python -m build
26+
27+
- name: Store distribution packages
28+
uses: actions/upload-artifact@v4
29+
with:
30+
name: python-package-distributions
31+
path: dist/
32+
33+
publish-to-pypi:
34+
name: Publish to PyPI
35+
needs: build
36+
runs-on: ubuntu-latest
37+
environment:
38+
name: pypi
39+
url: https://pypi.org/p/openf1-client
40+
permissions:
41+
id-token: write
42+
43+
steps:
44+
- name: Download distribution packages
45+
uses: actions/download-artifact@v4
46+
with:
47+
name: python-package-distributions
48+
path: dist/
49+
50+
- name: Publish to PyPI
51+
uses: pypa/gh-action-pypi-publish@release/v1

pyproject.toml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,20 +3,19 @@ requires = ["setuptools>=61.0", "wheel"]
33
build-backend = "setuptools.build_meta"
44

55
[project]
6-
name = "openf1-client"
6+
name = "OpenF1-python-client"
77
version = "1.0.0"
88
description = "A production-grade Python client SDK for the OpenF1 Formula 1 API"
99
readme = "README.md"
10-
license = {text = "MIT"}
10+
license = "MIT"
1111
requires-python = ">=3.10"
1212
authors = [
13-
{name = "OpenF1 Client Contributors"}
13+
{name = "Rohit", email = "rohit@rohit.ninja"}
1414
]
1515
keywords = ["formula1", "f1", "openf1", "api", "client", "telemetry", "racing"]
1616
classifiers = [
1717
"Development Status :: 4 - Beta",
1818
"Intended Audience :: Developers",
19-
"License :: OSI Approved :: MIT License",
2019
"Operating System :: OS Independent",
2120
"Programming Language :: Python :: 3",
2221
"Programming Language :: Python :: 3.10",
@@ -45,10 +44,11 @@ async = [
4544
]
4645

4746
[project.urls]
48-
Homepage = "https://github.com/openf1-client/openf1-python"
49-
Documentation = "https://github.com/openf1-client/openf1-python#readme"
50-
Repository = "https://github.com/openf1-client/openf1-python"
51-
Issues = "https://github.com/openf1-client/openf1-python/issues"
47+
Homepage = "https://github.com/rhtnr/openf1-python"
48+
Documentation = "https://github.com/rhtnr/openf1-python#readme"
49+
Repository = "https://github.com/rhtnr/openf1-python"
50+
Issues = "https://github.com/rhtnr/openf1-python/issues"
51+
Funding = "https://buymeacoffee.com/rhtnr"
5252

5353
[tool.setuptools.packages.find]
5454
where = ["src"]

0 commit comments

Comments
 (0)