Skip to content

descriptions_updated #188

descriptions_updated

descriptions_updated #188

name: Build Docs
on:
push:
branches:
- main
paths:
- 'docs/**'
- '.github/workflows/ibc_documentation.yml'
repository_dispatch:
permissions:
contents: write
jobs:
docs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v3
- name: Install dependencies
run: |
sudo apt install pandoc
pip install --upgrade pip
pip install sphinx sphinx_rtd_theme furo numpy pandas sphinx_design myst-parser nbsphinx IPython sphinx-copybutton
- name: Get description files
run: |
curl -L -O -H "Accept: application/vnd.github.v4.raw" -H "X-GitHub-Api-Version: 2022-11-28" https://api.github.com/repos/individual-brain-charting/public_analysis_code/contents/ibc_data/\{ibc_tasks.tsv,ibc_conditions.tsv,all_contrasts.tsv\}
- name: Build tasks.rst
run: |
python docs/create_tasks_rst.py
- name: Clone and install API
run: |
git clone https://github.com/individual-brain-charting/api.git
pip install -e api/
- name: Get get_data notebook
run: |
cp api/examples/get_data.ipynb docs/source/
- name: Build API reference page
run: |
sphinx-apidoc -f -o docs/source api/src/ibc_api -TE -t docs/source/_template
- name: Build HTML
run: |
sphinx-build -b html docs/source/ docs/build/html
- name: Deploy
uses: peaceiris/actions-gh-pages@v3
with:
publish_branch: gh-pages
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: docs/build/html
force_orphan: true