update github actions
This commit is contained in:
committed by
FilippoOlivo
parent
f95408838a
commit
9e6d5d5929
58
.github/workflows/deployer.yml
vendored
Normal file
58
.github/workflows/deployer.yml
vendored
Normal file
@@ -0,0 +1,58 @@
|
||||
name: "Deployer"
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- "*"
|
||||
|
||||
jobs:
|
||||
|
||||
docs: #######################################################################
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- name: Install Python dependencies
|
||||
run: python3 -m pip install .[doc]
|
||||
|
||||
- name: Build Documentation
|
||||
run: |
|
||||
make html
|
||||
working-directory: docs/
|
||||
|
||||
- name: Deploy
|
||||
uses: peaceiris/actions-gh-pages@v3
|
||||
with:
|
||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||
#deploy_key: ${{ secrets.DEPLOY_PRIVATE_KEY }}
|
||||
publish_dir: ./docs/build/html
|
||||
allow_empty_commit: true
|
||||
|
||||
release_github: #############################################################
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
contents: write
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: ncipollo/release-action@v1
|
||||
with:
|
||||
token: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
pypi: #######################################################################
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- name: Install build
|
||||
run: >-
|
||||
python -m pip install build --user
|
||||
|
||||
- name: Build a binary wheel and a source tarball
|
||||
run: >-
|
||||
python -m build --sdist --wheel --outdir dist/ .
|
||||
|
||||
- name: Publish distribution to PyPI
|
||||
if: startsWith(github.ref, 'refs/tags')
|
||||
uses: pypa/gh-action-pypi-publish@release/v1
|
||||
with:
|
||||
password: ${{ secrets.PYPI_API_TOKEN }}
|
||||
Reference in New Issue
Block a user