chore(deps): bump peaceiris/actions-gh-pages from 3 to 4 #2321
Workflow file for this run
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: Build and preview docs | |
on: | |
push: | |
branches-ignore: | |
- 'main' | |
tags-ignore: | |
- v* | |
pull_request: | |
types: | |
- opened | |
- reopened | |
- synchronize | |
- closed | |
concurrency: preview-${{ github.ref }} | |
jobs: | |
build-docs: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout source | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
submodules: true | |
- name: Set up Python 3.11 | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.11' | |
- name: Check for sudo | |
shell: bash | |
run: | | |
if type sudo >/dev/null 2>&1; then SUDO="sudo"; else SUDO=""; fi | |
echo "SUDO=$SUDO" >> $GITHUB_ENV | |
- name: Install dependencies | |
run: | | |
$SUDO bash -c "$(curl -fsSL http://neuro.debian.net/_files/neurodebian-travis.sh)" | |
$SUDO apt-get update -qq | |
$SUDO apt-get install git-annex-standalone | |
python -m pip install --upgrade pip setuptools wheel | |
python -m pip install -e ".[docs,neurokit2]" | |
- name: Configure git for datalad | |
run: | | |
git config --global user.email "[email protected]" | |
git config --global user.name "GITHUB CI Runner" | |
- name: Install ANTs | |
run: | | |
echo "++ Add universe repo" | |
sudo add-apt-repository -y universe | |
echo "++ Update package manager info" | |
sudo apt-get update -qq | |
echo "++ Downloading ANTs" | |
curl -fsSL -o ants.zip https://github.com/ANTsX/ANTs/releases/download/v2.5.1/ants-2.5.1-ubuntu-22.04-X64-gcc.zip | |
unzip ants.zip -d /opt | |
mv /opt/ants-2.5.1/bin/* /opt/ants-2.5.1 | |
rm ants.zip | |
echo "/opt/ants-2.5.1" >> $GITHUB_PATH | |
- name: Test build docs | |
run: | | |
BUILDDIR=_build/main make -C docs/ local | |
- name: Deploy preview | |
if: github.event_name == 'pull_request' | |
uses: rossjrw/pr-preview-action@v1 | |
with: | |
source-dir: docs/_build/main |