Merge pull request #3 from Heritage-XioN/add-workflow-action-for-CD-publish-to-pypi

added publish workflow
This commit is contained in:
HERITAGE-XION 2026-01-07 16:33:08 +01:00 committed by GitHub
commit 84f60d66aa
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 39 additions and 1 deletions

38
.github/workflows/publish.yml vendored Normal file
View File

@ -0,0 +1,38 @@
name: Publish to PyPI
on:
release:
types: [published]
jobs:
# The Safety Check
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: astral-sh/setup-uv@v5
- run: uv python install 3.10
- run: uv sync --all-extras --dev
- run: uv run pytest -x
# The Publisher
# This ONLY runs if 'test' passes successfully.
publish:
needs: test # <--- The Dependency You Requested
runs-on: ubuntu-latest
environment: pypi
permissions:
id-token: write # IMPORTANT: Required for Trusted Publishing
steps:
- uses: actions/checkout@v4
- name: Install uv
uses: astral-sh/setup-uv@v5
- name: Build package
run: uv build
- name: Publish to PyPI
# We use the official PyPA action for OIDC security
uses: pypa/gh-action-pypi-publish@release/v1

View File

@ -1,5 +1,5 @@
[project]
name = "metadata-scrubber-tool"
name = "metadata-scrubber"
version = "0.1.0"
description = "A privacy-focused CLI tool that removes sensitive metadata from image files"
readme = "README.md"