diff --git a/.github/workflows/tag_and_publish.yml b/.github/workflows/tag_and_publish.yml index abb2566..7cb025e 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 b427e4a..5eef8c3 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 4ff1545..440fafa 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"