From 92b8f51ca19e35f02924daea1f42e093d1f654cf Mon Sep 17 00:00:00 2001 From: Jerry Ma Date: Wed, 24 Jun 2020 22:44:03 -0400 Subject: [PATCH] update docs --- .gitignore | 2 +- README.rst | 28 ++++++++++++++++++++++++++++ mkdocs.yml | 2 ++ setup.cfg | 1 + tox.ini | 17 +++++++++++++++++ 5 files changed, 49 insertions(+), 1 deletion(-) create mode 100644 mkdocs.yml diff --git a/.gitignore b/.gitignore index 9b73111..c4ba8e0 100644 --- a/.gitignore +++ b/.gitignore @@ -20,7 +20,7 @@ MANIFEST # Sphinx docs/api docs/_build - +site/ # Eclipse editor project files .project .pydevproject diff --git a/README.rst b/README.rst index 29b3074..2ce577d 100644 --- a/README.rst +++ b/README.rst @@ -42,6 +42,34 @@ The license section from the README file of the `SZpack.v1.1.1` tarball: //================================================================================================== +Installation +------------ + +The SZpack depends on the +`GNU Scientific Library `_ (GSL), which has +to be installed and made available in the environment. + +The low level python interface comes along with SZPack also depends on +`SWIG `_. Please refer to the documentation +for how to install. + +To install ``szpack_wrapper``, + +.. code:: text + + $ gsl-config --version # check that GSL is installed + 2.6 + $ which swig # check that swig is installed + /usr/local/bin/swig + $ pip install szpack_wrapper + +Behind the scene, the ``SZpack`` v1.1.1 is bundled with this package in the +``szpack_wrapper/extern`` folder, and an accompanying ``setup_package.py`` file +is used to leverage the +`extension-helpers `_ +to build the code as a C extension. + + SZpackWrapper License --------------------- diff --git a/mkdocs.yml b/mkdocs.yml new file mode 100644 index 0000000..86991a6 --- /dev/null +++ b/mkdocs.yml @@ -0,0 +1,2 @@ +site_name: szpack_wrapper +docs_dir: docs/_build/html diff --git a/setup.cfg b/setup.cfg index eca6ebb..58de71a 100644 --- a/setup.cfg +++ b/setup.cfg @@ -26,6 +26,7 @@ test = pytest-astropy docs = sphinx-astropy + mkdocs [options.package_data] szpack_wrapper = data/* diff --git a/tox.ini b/tox.ini index 0e34915..c141dca 100644 --- a/tox.ini +++ b/tox.ini @@ -73,6 +73,23 @@ commands = pip freeze sphinx-build -W -b html . _build/html +[testenv:docs] +depends = build_docs +description = invoke mkdocs to serve the docs +extras = {[testenv:build_docs]extras} +changedir = {toxinidir} +commands = + mkdocs build --clean + python -c 'print("###### Starting local server. Press Control+C to stop server ######")' + mkdocs serve -a localhost:8888 + +[testenv:docs-deploy] +depends = {[testenv:docs]depends} +description = invoke mkdocs to deploy the docs +extras = {[testenv:build_docs]extras} +changedir = {[testenv:docs]changedir} +commands = mkdocs gh-deploy --clean + [testenv:linkcheck] changedir = docs description = check the links in the HTML docs