release #8
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: release | |
# Adapted from PreTeXt CLI | |
on: | |
# Allows you to run this workflow manually from the Actions tab. | |
workflow_dispatch: | |
jobs: | |
deploy: | |
name: Deploy to pypi | |
runs-on: ubuntu-latest | |
steps: | |
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it. | |
- uses: actions/checkout@v4 | |
# Sets up python3 | |
- uses: actions/setup-python@v5 | |
with: | |
python-version: '3.10' | |
# Setup poetry | |
- name: Install poetry 1.8.3 | |
run: | | |
python -m ensurepip | |
python -m pip install --upgrade pip | |
python -m pip install poetry==1.8.3 | |
- name: Install dependencies | |
shell: bash | |
run: python -m poetry install | |
- name: publish to pypi.org | |
env: | |
PYPI_TOKEN: ${{ secrets.PYPI_TOKEN }} | |
run: | | |
poetry build | |
poetry config pypi-token.pypi $PYPI_TOKEN | |
poetry publish | |
echo "Published to pypi.org" |