test-python-package-release 0.4.0__tar.gz → 0.5.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- test_python_package_release-0.5.0/.dockerignore +17 -0
- test_python_package_release-0.5.0/.github/.release-please-manifest.json +3 -0
- test_python_package_release-0.5.0/.github/workflows/docker-publish.yml +48 -0
- {test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/CHANGELOG.md +8 -0
- test_python_package_release-0.5.0/Dockerfile +18 -0
- {test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/PKG-INFO +22 -2
- {test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/README.md +20 -0
- {test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/pyproject.toml +1 -1
- {test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/src/test_python_package_release/__init__.py +1 -1
- {test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/uv.lock +2 -2
- test_python_package_release-0.4.0/.github/.release-please-manifest.json +0 -3
- {test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/.github/dependabot.yml +0 -0
- {test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/.github/release-please-config.json +0 -0
- {test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/.github/workflows/ci.yml +0 -0
- {test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/.github/workflows/claude-review.yml +0 -0
- {test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/.github/workflows/publish.yml +0 -0
- {test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/.github/workflows/release-please.yml +0 -0
- {test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/.gitignore +0 -0
- {test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/.pre-commit-config.yaml +0 -0
- {test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/.python-version +0 -0
- {test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/LICENSE +0 -0
- {test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/commitlint.config.cjs +0 -0
- {test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/docs/superpowers/plans/2026-05-30-python-package-release-template.md +0 -0
- {test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/docs/superpowers/specs/2026-05-30-python-package-release-template-design.md +0 -0
- {test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/src/test_python_package_release/calculator.py +0 -0
- {test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/src/test_python_package_release/strings.py +0 -0
- {test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/tests/__init__.py +0 -0
- {test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/tests/test_calculator.py +0 -0
- {test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/tests/test_strings.py +0 -0
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
name: Docker Publish
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
release:
|
|
5
|
+
types: [published]
|
|
6
|
+
workflow_dispatch:
|
|
7
|
+
|
|
8
|
+
env:
|
|
9
|
+
IMAGE_NAME: ${{ vars.DOCKERHUB_USERNAME }}/test-python-package-release
|
|
10
|
+
|
|
11
|
+
jobs:
|
|
12
|
+
docker:
|
|
13
|
+
runs-on: ubuntu-latest
|
|
14
|
+
permissions:
|
|
15
|
+
contents: read
|
|
16
|
+
steps:
|
|
17
|
+
- uses: actions/checkout@v4
|
|
18
|
+
|
|
19
|
+
- name: Docker meta
|
|
20
|
+
id: meta
|
|
21
|
+
uses: docker/metadata-action@v6
|
|
22
|
+
with:
|
|
23
|
+
images: ${{ env.IMAGE_NAME }}
|
|
24
|
+
# release-please tags look like "test-python-package-release-v1.2.3"
|
|
25
|
+
tags: |
|
|
26
|
+
type=semver,pattern={{version}},match=v(\d+\.\d+\.\d+.*)$
|
|
27
|
+
type=semver,pattern={{major}}.{{minor}},match=v(\d+\.\d+\.\d+.*)$
|
|
28
|
+
type=sha
|
|
29
|
+
|
|
30
|
+
- uses: docker/setup-qemu-action@v4
|
|
31
|
+
- uses: docker/setup-buildx-action@v4
|
|
32
|
+
|
|
33
|
+
- name: Login to Docker Hub
|
|
34
|
+
uses: docker/login-action@v4
|
|
35
|
+
with:
|
|
36
|
+
username: ${{ vars.DOCKERHUB_USERNAME }}
|
|
37
|
+
password: ${{ secrets.DOCKERHUB_TOKEN }}
|
|
38
|
+
|
|
39
|
+
- name: Build and push
|
|
40
|
+
uses: docker/build-push-action@v7
|
|
41
|
+
with:
|
|
42
|
+
context: .
|
|
43
|
+
platforms: linux/amd64,linux/arm64
|
|
44
|
+
push: true
|
|
45
|
+
tags: ${{ steps.meta.outputs.tags }}
|
|
46
|
+
labels: ${{ steps.meta.outputs.labels }}
|
|
47
|
+
cache-from: type=gha
|
|
48
|
+
cache-to: type=gha,mode=max
|
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [0.5.0](https://github.com/wozniakos10/test_python_package_release/compare/test-python-package-release-v0.4.0...test-python-package-release-v0.5.0) (2026-12-05)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Features
|
|
7
|
+
|
|
8
|
+
* **docker:** publish image to Docker Hub on release ([1c7ccec](https://github.com/wozniakos10/test_python_package_release/commit/1c7ccec3b0395be10c8678728b43eb94002ed239))
|
|
9
|
+
* **docker:** publish image to Docker Hub on release ([75695c7](https://github.com/wozniakos10/test_python_package_release/commit/75695c78082df0888927b68f94b313db16ef8cfa))
|
|
10
|
+
|
|
3
11
|
## [0.4.0](https://github.com/wozniakos10/test_python_package_release/compare/test-python-package-release-v0.3.2...test-python-package-release-v0.4.0) (2026-05-31)
|
|
4
12
|
|
|
5
13
|
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
FROM ghcr.io/astral-sh/uv:python3.13-bookworm-slim AS builder
|
|
2
|
+
|
|
3
|
+
WORKDIR /app
|
|
4
|
+
COPY pyproject.toml uv.lock README.md LICENSE ./
|
|
5
|
+
COPY src ./src
|
|
6
|
+
RUN uv build --wheel --out-dir /dist
|
|
7
|
+
|
|
8
|
+
FROM python:3.13-slim
|
|
9
|
+
|
|
10
|
+
LABEL org.opencontainers.image.source="https://github.com/wozniakos10/test-python-package-release"
|
|
11
|
+
|
|
12
|
+
COPY --from=builder /dist/*.whl /tmp/
|
|
13
|
+
RUN pip install --no-cache-dir /tmp/*.whl && rm /tmp/*.whl
|
|
14
|
+
|
|
15
|
+
RUN useradd --create-home appuser
|
|
16
|
+
USER appuser
|
|
17
|
+
|
|
18
|
+
CMD ["python", "-c", "import test_python_package_release as p; print(f'test-python-package-release {p.__version__}'); print('2 + 3 =', p.add(2, 3))"]
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
Metadata-Version: 2.
|
|
1
|
+
Metadata-Version: 2.5
|
|
2
2
|
Name: test-python-package-release
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.5.0
|
|
4
4
|
Summary: Template library demonstrating Python package release CI/CD
|
|
5
5
|
Author-email: Dawid Wozniak <wozniakos10@gmail.com>
|
|
6
6
|
License: MIT License
|
|
@@ -137,8 +137,28 @@ Release PR merged ──▶ release-please tags + creates GitHub Release
|
|
|
137
137
|
└─ publish.yml ──▶ uv build
|
|
138
138
|
──▶ TestPyPI (OIDC)
|
|
139
139
|
──▶ PyPI (OIDC, gated env)
|
|
140
|
+
│
|
|
141
|
+
└─ docker-publish.yml ──▶ Docker Hub
|
|
142
|
+
(<version>, <major.minor>, sha-*)
|
|
143
|
+
```
|
|
144
|
+
|
|
145
|
+
## Docker image
|
|
146
|
+
|
|
147
|
+
Each GitHub Release also publishes a multi-arch image (amd64, arm64) to
|
|
148
|
+
Docker Hub. To try it locally:
|
|
149
|
+
|
|
150
|
+
```bash
|
|
151
|
+
docker build -t test-python-package-release .
|
|
152
|
+
docker run --rm test-python-package-release
|
|
140
153
|
```
|
|
141
154
|
|
|
155
|
+
Required repo configuration (Settings → Secrets and variables → Actions):
|
|
156
|
+
|
|
157
|
+
- Variable `DOCKERHUB_USERNAME`: your Docker Hub username
|
|
158
|
+
- Secret `DOCKERHUB_TOKEN`: a Docker Hub
|
|
159
|
+
[personal access token](https://app.docker.com/settings/personal-access-tokens)
|
|
160
|
+
with Read & Write scope
|
|
161
|
+
|
|
142
162
|
## First-time setup after cloning the template
|
|
143
163
|
|
|
144
164
|
1. **Rename the package**: update `name` in `pyproject.toml`, the directory
|
|
@@ -103,8 +103,28 @@ Release PR merged ──▶ release-please tags + creates GitHub Release
|
|
|
103
103
|
└─ publish.yml ──▶ uv build
|
|
104
104
|
──▶ TestPyPI (OIDC)
|
|
105
105
|
──▶ PyPI (OIDC, gated env)
|
|
106
|
+
│
|
|
107
|
+
└─ docker-publish.yml ──▶ Docker Hub
|
|
108
|
+
(<version>, <major.minor>, sha-*)
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
## Docker image
|
|
112
|
+
|
|
113
|
+
Each GitHub Release also publishes a multi-arch image (amd64, arm64) to
|
|
114
|
+
Docker Hub. To try it locally:
|
|
115
|
+
|
|
116
|
+
```bash
|
|
117
|
+
docker build -t test-python-package-release .
|
|
118
|
+
docker run --rm test-python-package-release
|
|
106
119
|
```
|
|
107
120
|
|
|
121
|
+
Required repo configuration (Settings → Secrets and variables → Actions):
|
|
122
|
+
|
|
123
|
+
- Variable `DOCKERHUB_USERNAME`: your Docker Hub username
|
|
124
|
+
- Secret `DOCKERHUB_TOKEN`: a Docker Hub
|
|
125
|
+
[personal access token](https://app.docker.com/settings/personal-access-tokens)
|
|
126
|
+
with Read & Write scope
|
|
127
|
+
|
|
108
128
|
## First-time setup after cloning the template
|
|
109
129
|
|
|
110
130
|
1. **Rename the package**: update `name` in `pyproject.toml`, the directory
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
version = 1
|
|
2
|
-
revision =
|
|
2
|
+
revision = 5
|
|
3
3
|
requires-python = ">=3.11"
|
|
4
4
|
|
|
5
5
|
[[package]]
|
|
@@ -367,7 +367,7 @@ wheels = [
|
|
|
367
367
|
|
|
368
368
|
[[package]]
|
|
369
369
|
name = "test-python-package-release"
|
|
370
|
-
version = "0.
|
|
370
|
+
version = "0.5.0"
|
|
371
371
|
source = { editable = "." }
|
|
372
372
|
|
|
373
373
|
[package.dev-dependencies]
|
{test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/.github/dependabot.yml
RENAMED
|
File without changes
|
|
File without changes
|
{test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/.github/workflows/ci.yml
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/.pre-commit-config.yaml
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/commitlint.config.cjs
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/tests/test_calculator.py
RENAMED
|
File without changes
|
{test_python_package_release-0.4.0 → test_python_package_release-0.5.0}/tests/test_strings.py
RENAMED
|
File without changes
|