Commit 47c15f72 authored by Christoph Ruegge's avatar Christoph Ruegge
Browse files

Add versioning and tarball creation

parent 63127c19
......@@ -4,19 +4,23 @@ stages:
build:
stage: build
before_script:
- cd docs
script:
- nix-shell -p python3Packages.sphinx python3Packages.numpydoc python3Packages.pnam --run "make html"
- VERSION=$(git describe --long | cut -d- -f1)
- mkdir -p tarball
- git archive --prefix=ProxPython/ HEAD | gzip > tarball/proxpython-$VERSION.tar.gz
- cd docs
- nix-shell -p python3Packages.sphinx python3Packages.numpydoc python3Packages.pnam --run "make VERSION=$VERSION html"
artifacts:
paths:
- docs/_build/
- tarball
only:
- release
deploy:
stage: deploy
script:
- rsync -av docs/_build/html/ /var/www/num/proxtoolbox/
- rsync -av docs/_build/html/ /var/www/num/proxtoolbox/
- rsync -av tarball/ /var/www/num/proxtoolbox/downloads/
only:
- release
......@@ -40,10 +40,12 @@ extensions = [
'numpydoc'
]
version = os.environ.get('VERSION', '(0+1j)')
rst_epilog = """
.. _ProxMatlabTar: http://num.math.uni-goettingen.de/~r.luke/proxtoolbox-matlab.tar.gz
.. _ProxPythonTar: http://num.math.uni-goettingen.de/~r.luke/proxtoolbox-python.tar.gz
"""
.. _ProxPythonTar: http://num.math.uni-goettingen.de/proxtoolbox/downloads/proxpython-{version}.tar.gz
.. |version| replace:: {version}
""".format(version=version)
autosummary_generate = True
......
......@@ -14,10 +14,10 @@ Welcome to ProxToolbox's documentation!
Matlab version
--------------
`Download <ProxMatlabTar_>`_
`Download <http://num.math.uni-goettingen.de/~r.luke/proxtoolbox-matlab.tar.gz>`_
Python version
--------------
Python version |version|
------------------------
`Download <ProxPythonTar_>`_
......
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