Skip to content

Bump pytest-xdist from 3.5.0 to 3.6.1 in /requirements #577

Bump pytest-xdist from 3.5.0 to 3.6.1 in /requirements

Bump pytest-xdist from 3.5.0 to 3.6.1 in /requirements #577

Workflow file for this run

name: docs
on:
pull_request:
push:
branches: [ main ]
tags:
- '*'
jobs:
build-docs:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v4
with:
# Fetch the history for all tags and branches
# so that the correct version string can be constructed
# by setuptools_scm.
fetch-depth: 0
- uses: actions/setup-python@v5
with:
python-version: "3.10"
- name: install dependencies
run: |
python -m pip install \
-r requirements/minimal.txt \
-r requirements/docs.txt \
build \
packaging
- name: generate version string
run: python -m build --sdist
- name: build Docs
run: make -C docs
- name: move docs
if: github.event_name == 'push'
run: |
cp docs/is_new_stable.py /tmp/
mv docs/_build/html /tmp/${GITHUB_REF_NAME}
git checkout gh-pages
rm -fr ${GITHUB_REF_NAME}
mv /tmp/${GITHUB_REF_NAME} .
find ${GITHUB_REF_NAME} -name __pycache__ -exec rm -r {} +
rm -fr latest
ln -s ${GITHUB_REF_NAME} latest
- name: check if tag is new stable
if: github.event_name == 'push' && github.ref_type == 'tag'
run: |
if [ -f stable ]; then
export STABLE=$(readlink stable)
else
export STABLE=0
fi
if python /tmp/is_new_stable.py ${STABLE} ${GITHUB_REF_NAME}; then
# Use for "stable" docs path.
echo "new stable is ${GITHUB_REF_NAME}"
rm -fr stable
ln -s ${GITHUB_REF_NAME} stable
echo "STABLE_PATH=stable" >> $GITHUB_ENV
fi
- name: commit to gh-pages
if: github.event_name == 'push'
uses: stefanzweifel/git-auto-commit-action@v5
with:
commit_message: deploy ${{ github.ref }}
branch: gh-pages
file_pattern: ${{ github.ref_name }} latest ${{ env.STABLE_PATH }}