-
Notifications
You must be signed in to change notification settings - Fork 3
/
entry.sh
executable file
·74 lines (56 loc) · 1.01 KB
/
entry.sh
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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
#!/bin/sh -e
test() {
pytest --cov=cartpole --cov-report term-missing --pep8 ###--cov-fail-under 50
}
_codecov() {
codecov
}
build() {
python setup.py sdist bdist_wheel
}
publish() {
twine upload --skip-existing dist/*
}
release(){
bumpversion --tag --commit --message "[skip ci] Update version \{current_version\} --> \{new_version\}" patch
gitchangelog > CHANGELOG.md
}
docs() {
sphinx-build -d docs/build/doctrees source docs/build/html
}
# Main options
case "$1" in
test)
shift
test "$@"
exit $?
;;
codecov)
shift
_codecov "$@"
exit $?
;;
build)
shift
build "$@"
exit $?
;;
release)
shift
release "$@"
exit $?
;;
publish)
shift
publish "$@"
exit $?
;;
docs)
shift
docs "$@"
exit $?
;;
*)
echo "Usage: $0 {test|codecov|build|release|publish|docs}"
exit 1
esac