diff --git a/setup.py b/setup.py index 8a8e3f476..e3ca507f6 100755 --- a/setup.py +++ b/setup.py @@ -1,12 +1,22 @@ #!/usr/bin/env python3 -from setuptools import setup, find_packages +from setuptools import setup, find_packages, Command import sys import os if sys.version_info[:3] < (3, 4, 3): raise Exception("You need at least Python 3.4.3 to run ARTIQ") +class PushDocCommand(Command): + description = "uploads the documentation to m-labs.hk" + user_options = [] + def initialize_options(self): + pass + def finalize_options(self): + pass + def run(self): + os.system("rsync -avz doc/manual/_build/html/ shell.serverraum.org:~/web/m-labs.hk/artiq/manual") + requirements = [ "sphinx", "sphinx-argparse", "pyserial", "numpy", "scipy", "python-dateutil", "prettytable", "h5py", "pydaqmx", "pyelftools", @@ -52,5 +62,6 @@ setup( ext_modules=[], entry_points={ "console_scripts": scripts, - } + }, + cmdclass={"push_doc":PushDocCommand} )