dogfood own action

This commit is contained in:
Andrew Cassidy 2024-08-20 00:28:48 -07:00
parent 629d931979
commit 1f01bda2f4

View File

@ -40,9 +40,9 @@ jobs:
run: python -m unittest -v run: python -m unittest -v
deploy: deploy:
needs: test # needs: test
runs-on: ubuntu-latest runs-on: ubuntu-latest
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags') # if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
@ -56,7 +56,6 @@ jobs:
run: | run: |
python -m pip install --upgrade pip python -m pip install --upgrade pip
python -m pip install setuptools wheel twine python -m pip install setuptools wheel twine
python -m pip install . # Self hosting!
- name: Install pypa/build - name: Install pypa/build
run: python -m pip install build --user run: python -m pip install build --user
@ -64,10 +63,9 @@ jobs:
- name: Build a binary wheel and source tarball - name: Build a binary wheel and source tarball
run: python -m build --sdist --wheel --outdir dist/ run: python -m build --sdist --wheel --outdir dist/
- name: Get version name and body - name: Get version info
run: | id: yaclog-show
echo "VERSION_TILE=$(yaclog show -n)" >> $GITHUB_ENV uses: ./
echo "$(yaclog show -mb)" >> RELEASE.md
- name: Publish to PyPI - name: Publish to PyPI
uses: pypa/gh-action-pypi-publish@release/v1 uses: pypa/gh-action-pypi-publish@release/v1
@ -78,7 +76,7 @@ jobs:
uses: softprops/action-gh-release@v2 uses: softprops/action-gh-release@v2
with: with:
files: dist/* files: dist/*
name: ${{ env.VERSION_TITLE }} name: ${{ steps.yaclog-show.outputs.name }}
body_path: RELEASE.md body_path: ${{ steps.yaclog-show.outputs.body_file }}
env: env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}