Commit 5afe4a5a authored by Ryan Fisher's avatar Ryan Fisher

Merge branch 'docs' into 'master'

Added CI to auto-build sphinx docs

See merge request !61
parents a1e5109f ce63d00a
Pipeline #57448 passed with stages
in 10 minutes and 12 seconds
stages:
- build
- deploy
- package
- test
- docs
- deploy
# -- build ------------------
......@@ -48,10 +50,10 @@ build:wheel:macos:
paths:
- '*.whl'
# -- deploy -----------------
# -- package ----------------
.deploy:debian: &deploy-debian
stage: deploy
.package:debian: &package-debian
stage: package
dependencies:
- build:sdist
variables:
......@@ -75,12 +77,12 @@ build:wheel:macos:
- '*.deb'
- '*.changes'
deploy:stretch:
<<: *deploy-debian
package:stretch:
<<: *package-debian
image: ligo/base:stretch
.deploy:el7: &deploy-el
stage: deploy
.package:el7: &package-el
stage: package
dependencies:
- build:sdist
variables:
......@@ -105,8 +107,8 @@ deploy:stretch:
- '*.rpm'
- '*.spec'
deploy:el7:
<<: *deploy-el
package:el7:
<<: *package-el
image: ligo/base:el7
# -- test -------------------
......@@ -146,7 +148,7 @@ test:el7:
stage: test
image: ligo/lalsuite-dev:el7
dependencies:
- deploy:el7
- package:el7
- build:sdist
variables:
GIT_STRATEGY: none
......@@ -161,7 +163,7 @@ test:stretch:python2:
stage: test
image: ligo/lalsuite-dev:stretch
dependencies:
- deploy:stretch
- package:stretch
- build:sdist
variables:
GIT_STRATEGY: none
......@@ -178,7 +180,7 @@ test:stretch:python3:
stage: test
image: ligo/lalsuite-dev:stretch
dependencies:
- deploy:stretch
- package:stretch
- build:sdist
variables:
GIT_STRATEGY: none
......@@ -190,3 +192,54 @@ test:stretch:python3:
# extract and run the tests
- tar -xf *.tar.* --strip-components 1 --wildcards lscsoft-glue*/test
- make -C test PYTHON=python3
docs:
stage: docs
image: python
variables:
PIP_CACHE_DIR: "$CI_PROJECT_DIR/.cache/pip"
before_script:
# install docs requirements
- python -m pip install sphinx sphinx_rtd_theme
# install glue and lalsuite (everything else is in setup.py)
- python -m pip install . lalsuite
script:
- glue_version=$(python setup.py --version)
- mkdir -v docs
- cd docs
# generate docs skeleton
- python -m sphinx.ext.apidoc
--module-first
--separate
--full
--ext-autodoc
--ext-intersphinx
--doc-project "lscsoft-glue"
--doc-author "The LIGO Scientific Collaboration and The Virgo Collaboration"
--doc-version "${glue_version}"
--output-dir .
../glue
# use module page as index
- mv -v glue.rst index.rst
# use sphinx_rtd_theme
- sed -i 's/alabaster/sphinx_rtd_theme/g' conf.py
# run sphinx to generate docs
- python -m sphinx -M html . build
artifacts:
paths:
- docs/build
cache:
paths:
- .cache/pip
pages:
stage: deploy
dependencies:
- docs
only:
- tags
script:
- mv docs/build/html public
artifacts:
paths:
- public
......@@ -114,7 +114,7 @@ setup(
description = "Grid LSC User Engine",
long_description = longdesc,
long_description_content_type = 'text/markdown',
url = "http://www.lsc-group.phys.uwm.edu/daswg/",
url = "https://docs.ligo.org/lscsoft/glue/",
license = 'GPLv2+',
packages = [ 'glue', 'glue.ligolw', 'glue.ligolw.utils', 'glue.segmentdb', 'glue.auth'],
install_requires=install_requires,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment