Skip to content

[CD] Upload package to PyPI when creating a release #48

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Mar 26, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 34 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: PyPI Upload

on:
release:
types:
- published

jobs:
dist:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: hynek/build-and-inspect-python-package@v2

publish:
needs: [dist]
environment: pypi
permissions:
id-token: write
attestations: write
runs-on: ubuntu-latest

steps:
- uses: actions/download-artifact@v4
with:
name: Packages
path: dist

- name: Generate artifact attestation for sdist and wheel
uses: actions/attest-build-provenance@v2
with:
subject-path: "dist/*"

- uses: pypa/gh-action-pypi-publish@release/v1
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ build-backend = "hatchling.build"
[project]
name = "idd"
version = "0.1.0"
description = "Add your description here"
description = "A tool for performing interactive dynamic differential debugging capable to identify functional and performance regressions."
readme = "README.md"
authors = [
{ name = "Martin Vassilev" },
Expand Down
4 changes: 4 additions & 0 deletions src/idd/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -470,3 +470,7 @@ def main() -> None:
disable_assembly = args["disable_assembly"]
dd = DiffDebug(disable_assembly, disable_registers, base_only)
dd.run()


if __name__ == "__main__":
main()