-
Notifications
You must be signed in to change notification settings - Fork 0
/
pavement.py
executable file
·49 lines (36 loc) · 909 Bytes
/
pavement.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
"""paver config file"""
# from testing python book
from paver.easy import sh
from paver.tasks import needs, task
@task
def tests():
"""unit testing"""
# sh('nosetests --verbose --cover-package=techminer --cover-tests '
# ' --with-doctest --rednose ./techminer/')
sh("pytest --doctest-modules")
@task
def pylint():
"""pyltin"""
sh("pylint ./techminer/")
@task
def pypi():
"""Instalation on PyPi"""
sh("python3 setup.py sdist")
sh("twine upload dist/*")
@task
def local():
"""local install"""
# sh("pip3 uninstall --yes techminer")
sh("pip3 install .")
@task
def sphinx():
"""Document creation using Shinx"""
sh("cd sphinx; make html; cd ..")
sh("rm -rf docs/*")
sh("mv sphinx/_build/html/* docs/")
sh("rm -R sphinx/_build/doctrees/*")
@needs("nosetests", "pylint", "sphinx")
@task
def default():
"""default"""
pass