-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #57 from Caltech-IPAC/FIREFLY-1440-cd-gh-action
FIREFLY-1440: Set up continuous deployment for documentation website
- Loading branch information
Showing
24 changed files
with
290 additions
and
121 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
name: "Publish documentation" | ||
on: | ||
push: | ||
branches: | ||
- master | ||
|
||
workflow_dispatch: # Manual trigger | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- uses: actions/setup-python@v5 | ||
with: | ||
python-version: '3.10' | ||
cache: 'pip' | ||
|
||
- name: Create environment | ||
run: | | ||
pip install --upgrade pip | ||
python -m venv .venv | ||
source .venv/bin/activate | ||
- name: Install dependencies | ||
run: pip install -r requirements.txt | ||
|
||
- name: Install package | ||
run: pip install -e . | ||
|
||
- name: Build docs | ||
run: | | ||
cd docs | ||
make clean | ||
make html | ||
- name: Deploy docs | ||
uses: peaceiris/actions-gh-pages@v3 | ||
with: | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
publish_dir: ./docs/_build/html | ||
|
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
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
This file was deleted.
Oops, something went wrong.
Empty file.
This file was deleted.
Oops, something went wrong.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
# Minimal makefile for Sphinx documentation | ||
# | ||
|
||
# You can set these variables from the command line, and also | ||
# from the environment for the first two. | ||
SPHINXOPTS ?= | ||
SPHINXBUILD ?= sphinx-build | ||
SOURCEDIR = . | ||
BUILDDIR = _build | ||
|
||
# Put it first so that "make" without argument is like "make help". | ||
help: | ||
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) | ||
|
||
.PHONY: help Makefile | ||
|
||
# Catch-all target: route all unknown targets to Sphinx using the new | ||
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). | ||
%: Makefile | ||
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
# Configuration file for the Sphinx documentation builder. | ||
# | ||
# For the full list of built-in configuration values, see the documentation: | ||
# https://www.sphinx-doc.org/en/master/usage/configuration.html | ||
|
||
# -- Project information ----------------------------------------------------- | ||
# https://www.sphinx-doc.org/en/master/usage/configuration.html#project-information | ||
|
||
project = 'firefly_client' | ||
copyright = '2024, Caltech/IPAC Firefly Developers' | ||
author = 'Caltech/IPAC Firefly Developers' | ||
|
||
# -- General configuration --------------------------------------------------- | ||
# https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration | ||
|
||
extensions = [ | ||
'sphinx_automodapi.automodapi', | ||
'myst_parser' | ||
] | ||
|
||
templates_path = ['_templates'] | ||
exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store'] | ||
|
||
|
||
# -- Options for HTML output ------------------------------------------------- | ||
# https://www.sphinx-doc.org/en/master/usage/configuration.html#options-for-html-output | ||
|
||
html_theme = 'pydata_sphinx_theme' | ||
html_static_path = ['_static'] | ||
html_js_files = ["custom-icon.js"] | ||
|
||
html_last_updated_fmt = '' | ||
|
||
# See https://pydata-sphinx-theme.readthedocs.io/en/stable/user_guide/layout.html | ||
html_theme_options = { | ||
"icon_links": [ | ||
{ | ||
"name": "GitHub", | ||
"url": "https://github.com/Caltech-IPAC/firefly_client", | ||
"icon": "fa-brands fa-github", | ||
}, | ||
{ | ||
"name": "PyPI", | ||
"url": "https://pypi.org/project/firefly-client", | ||
"icon": "fa-custom fa-pypi", | ||
}, | ||
], | ||
"footer_start": ["copyright", "last-updated"], | ||
"footer_end": ["sphinx-version", "theme-version"], | ||
} | ||
|
||
|
||
# -- Options for extensions ------------------------------------------------- | ||
myst_heading_anchors = 3 |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
################# | ||
Local development | ||
################# | ||
|
||
Get latest source from ``master`` branch at https://github.com/Caltech-IPAC/firefly_client. | ||
|
||
|
||
Environment Setup | ||
----------------- | ||
|
||
TBD | ||
|
||
|
||
Building documentation | ||
---------------------- | ||
|
||
Make sure you have the virtual/conda environment activated and documentation | ||
dependencies installed in that environment. | ||
|
||
Then do: | ||
|
||
.. code-block:: shell | ||
cd docs | ||
make clean && make html | ||
Open ``docs/_build/html/index.html`` in your browser to see the documentation | ||
website. | ||
|
||
Each time you make a change in documentation source, build it using | ||
above command and reload the above file in browser. |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
############### | ||
Developer Guide | ||
############### | ||
|
||
|
||
.. toctree:: | ||
:maxdepth: 2 | ||
|
||
guide | ||
new-release-procedure.md | ||
|
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
Oops, something went wrong.