-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathlaunch.bat
More file actions
48 lines (36 loc) · 886 Bytes
/
Copy pathlaunch.bat
File metadata and controls
48 lines (36 loc) · 886 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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
@echo off
set "delimiters=------------------------------------------------------------"
echo %delimiters%
echo Launching!
echo %delimiters%
:: Get current directory
set "DIR=%~dp0"
:: Create virtualenv
if not exist "%DIR%\venv" (
python -m venv "%DIR%\venv"
echo %delimiters%
echo Virtualenv created
echo %delimiters%
)
:: Activate env
call "%DIR%\venv\Scripts\activate.bat"
:: Upgrade pip
python -m pip install --upgrade pip
:: Install dependencies
pip install -r "%DIR%\requirements.txt"
:: Install briefcase
pip install briefcase
:: Run the app in dev mode
briefcase dev
:: See if there are errors, if so, exit
if %errorlevel% neq 0 (
echo %delimiters%
echo There was an error, exiting...
echo %delimiters%
exit /b 1
)
echo %delimiters%
echo See you soon!
echo %delimiters%
:: Deactivate virtualenv
call "%DIR%\venv\Scripts\deactivate.bat"