Skip to content

Commit

Permalink
improved release process
Browse files Browse the repository at this point in the history
  • Loading branch information
LucaMarconato committed Jan 3, 2025
1 parent 92dbde1 commit a29ecb4
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 35 deletions.
23 changes: 0 additions & 23 deletions .github/workflows/build.yaml

This file was deleted.

24 changes: 12 additions & 12 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,26 +5,26 @@ on:
types: [published]

jobs:
release:
# requires that you have put your twine API key in your
# github secrets (see readme for details)
package_and_release:
runs-on: ubuntu-latest
if: contains(github.ref, 'tags')
if: startsWith(github.ref, 'refs/tags/v')
steps:
- name: Checkout code
uses: actions/checkout@v3

- name: Set up Python 3.10
- uses: actions/checkout@v3
- name: Set up Python 3.12
uses: actions/setup-python@v4
with:
python-version: "3.10"

python-version: "3.12"
cache: pip
- name: Install build dependencies
run: python -m pip install --upgrade pip wheel twine build
- name: Build package
run: python -m build
- name: Check package
run: twine check --strict dist/*.whl
- name: Install hatch
run: pip install hatch

- name: Build project for distribution
run: hatch build

- name: Publish a Python distribution to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
Expand Down

0 comments on commit a29ecb4

Please sign in to comment.