Skip to content

Commit

Permalink
Try to imporve release GH action (borrowed from uproot5.git)
Browse files Browse the repository at this point in the history
  • Loading branch information
oshadura committed Dec 4, 2023
1 parent 1029985 commit b274284
Show file tree
Hide file tree
Showing 3 changed files with 39 additions and 13 deletions.
37 changes: 30 additions & 7 deletions .github/workflows/pypi-tag-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,34 @@ jobs:
run: |
python -m pip install --upgrade pip
pip install setuptools wheel twine
- name: Build and publish
env:
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
- name: Check MANIFEST
run: |
check-manifest --verbose
- name: Build a wheel and a sdist
run: |
python setup.py sdist
python setup.py bdist_wheel --universal
twine upload dist/*
python -m build --outdir dist/ .
- name: Verify the distribution
run: twine check dist/*

- uses: actions/upload-artifact@v3
with:
path: dist/*

publish:
needs: [dist]
runs-on: ubuntu-latest
if: github.event_name == 'release' && github.event.action == 'published'

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

- uses: pypa/gh-action-pypi-publish@release/v1
with:
user: ${{ secrets.PYPI_USERNAME }}
password: ${{ secrets.PYPI_PASSWORD }}
11 changes: 7 additions & 4 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
prune **
graft coffea_casa
graft tests

include LICENSE
include README.md
include pyproject.toml
include MANIFEST.in

include requirements.txt
include coffea_casa/*.py
include coffea_casa/*.yaml
include coffea_casa/_version.py
global-exclude __pycache__ *.py[cod]
4 changes: 2 additions & 2 deletions coffea_casa/_version.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,5 @@
__version_tuple__: VERSION_TUPLE
version_tuple: VERSION_TUPLE

__version__ = version = '2023.8.12.dev44+g2807d2c.d20231204'
__version_tuple__ = version_tuple = (2023, 8, 12, 'dev44', 'g2807d2c.d20231204')
__version__ = version = '2023.8.12.dev47+gb7c8cf5.d20231204'
__version_tuple__ = version_tuple = (2023, 8, 12, 'dev47', 'gb7c8cf5.d20231204')

0 comments on commit b274284

Please sign in to comment.