Skip to content

[FIX] Avoid doc action on forks #97

[FIX] Avoid doc action on forks

[FIX] Avoid doc action on forks #97

Workflow file for this run

name: neuromaps-docs
on:
workflow_dispatch:
push:
branches:
- main
permissions:
contents: read
pages: write
id-token: write
jobs:
deploy_page:
if: github.repository_owner == 'netneurolab'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Python 3.8
uses: actions/setup-python@v4
with:
python-version: 3.8
- name: Install dependencies
run: |
pip install -r docs/requirements.txt
while true; do
wget --retry-connrefused --waitretry=1 --read-timeout=20 --timeout=15 -t 0 --no-dns-cache -c \
https://www.humanconnectome.org/storage/app/media/workbench/workbench-linux64-v1.5.0.zip && break
done
unzip workbench-linux64-v1.5.0.zip -d ${HOME}
echo "$HOME/workbench/bin_linux64" >> $GITHUB_PATH
- name: Install neuromaps
run: |
pip install .
- name: Build the docs
run: |
cd docs && make clean html
- name: Upload artifact
uses: actions/upload-pages-artifact@v2
with:
path: 'docs/_build/html'
- name: Deploy to GitHub Pages
uses: actions/deploy-pages@v2