-
Notifications
You must be signed in to change notification settings - Fork 5
/
make.bat
58 lines (48 loc) · 1.12 KB
/
make.bat
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
@ECHO OFF
pushd %~dp0
REM Simple make.bat to simplify repetitive build env management tasks under Windows
if "%1" == "install" goto install
if "%1" == "tests" goto tests
if "%1" == "doc" goto doc
if "%1" == "build" goto build
if "%1" == "clean" goto clean
if "%1" == "fresh-build" goto fresh-build
:install
Echo ^>^>^> Installing...
pip install -e .[freeze]
Echo ^>^>^> Installation complete.
goto end
:tests
Echo ^>^>^> Installing test dependencies...
pip install -e .[tests]
Echo ^>^>^> Running tests...
pytest
goto end
:doc
Echo ^>^>^> Installing documentation dependencies...
pip install -e .[doc]
Echo ^>^>^> Building documentation...
chdir /d doc
call make.bat clean
call make.bat html
chdir /d ..
Echo ^>^>^> Documentation complete.
goto end
:build
Echo ^>^>^> Freezing using pyinstaller
pyinstaller frozen.spec
goto end
:clean
Echo ^>^>^> Cleaning up build files...
rmdir /s /q build > /NUL 2>&1
rmdir /s /q dist > /NUL 2>&1
goto end
:fresh-build
Echo ^>^>^> Cleaning up build files...
rmdir /s /q build > /NUL 2>&1
rmdir /s /q dist > /NUL 2>&1
Echo ^>^>^> Freezing using pyinstaller
pyinstaller frozen.spec
goto end
:end
popd