From d7a98aef2833476871720a96f40fb0b46110befc Mon Sep 17 00:00:00 2001 From: hannalee2 Date: Thu, 3 Oct 2024 13:06:09 -0700 Subject: [PATCH] Add source code location --- .github/workflows/tag_and_publish.yml | 28 +++++++++++++++++++++++++++ docs/source/conf.py | 4 +++- parallax/__init__.py | 2 +- 3 files changed, 32 insertions(+), 2 deletions(-) diff --git a/.github/workflows/tag_and_publish.yml b/.github/workflows/tag_and_publish.yml index abb2566d..7cb025e1 100644 --- a/.github/workflows/tag_and_publish.yml +++ b/.github/workflows/tag_and_publish.yml @@ -64,3 +64,31 @@ jobs: uses: pypa/gh-action-pypi-publish@release/v1 with: password: ${{ secrets.AIND_PYPI_TOKEN }} + + + # Job 2: Build Documentation for Pushes to Main + build-docs: + runs-on: ubuntu-latest + steps: + # Step 1: Checkout the repository + - name: Checkout Repository + uses: actions/checkout@v3 + + # Step 2: Set up Python + - name: Set up Python + uses: actions/setup-python@v4 + with: + python-version: '3.8' + + # Step 3: Install dependencies (including Sphinx) + - name: Install Dependencies + run: | + python -m pip install --upgrade pip + pip install -r docs/requirements.txt + + # Step 4: Build the documentation + - name: Build Documentation + run: | + sphinx-build -b html docs/source docs/_build + # Fail the workflow if documentation build fails + continue-on-error: false \ No newline at end of file diff --git a/docs/source/conf.py b/docs/source/conf.py index b427e4a3..5eef8c30 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -11,6 +11,8 @@ from docutils.parsers.rst import roles from docutils import nodes +sys.path.insert(0, os.path.abspath('../../parallax')) + INSTITUTE_NAME = "Allen Institute for Neural Dynamics" project = 'Parallax' @@ -62,7 +64,7 @@ def blue_role(name, rawtext, text, lineno, inliner, options={}, content=[]): roles.register_local_role('yellow', yellow_role) roles.register_local_role('blue', blue_role) -html_static_path = ['_static'] +html_static_path = ['_static'] html_css_files = [ 'custom.css', ] \ No newline at end of file diff --git a/parallax/__init__.py b/parallax/__init__.py index 4ff15457..440fafae 100644 --- a/parallax/__init__.py +++ b/parallax/__init__.py @@ -4,7 +4,7 @@ import os -__version__ = "0.38.3" +__version__ = "0.38.4" # allow multiple OpenMP instances os.environ["KMP_DUPLICATE_LIB_OK"] = "True"