forked from exhuma/puresnmp
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtasks.py
More file actions
31 lines (25 loc) · 667 Bytes
/
Copy pathtasks.py
File metadata and controls
31 lines (25 loc) · 667 Bytes
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
from invoke import task
def generate_type_hierarchy(ctx):
"""
Generate a document containing the available variable types.
"""
ctx.run("./env/bin/python -m puresnmp.types > docs/typetree.rst")
@task
def doc(ctx):
generate_type_hierarchy(ctx)
ctx.run(
"./env/bin/sphinx-apidoc "
"-o docs/developer_guide/api "
"-f "
"-e "
"puresnmp "
"puresnmp/test"
)
with ctx.cd("docs"):
ctx.run("make html")
@task
def publish(ctx):
ctx.run("rm -rf dist")
ctx.run("python3 setup.py bdist_wheel --universal")
ctx.run("python3 setup.py sdist")
ctx.run("twine upload dist/*")