Skip to content

Commit

Permalink
Update run_main.bat
Browse files Browse the repository at this point in the history
  • Loading branch information
KorryKatti committed Mar 15, 2024
1 parent d72790d commit 52b1cbe
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions run_main.bat
Original file line number Diff line number Diff line change
@@ -1,7 +1,13 @@
@echo off
python -c "import sys; sys.exit(0 if __import__('importlib.util').find_spec('customtkinter') else 1)"

if not exist myenv (
python -m venv myenv
)

call myenv\Scripts\activate.bat
myenv\Scripts\python.exe -c "import sys; sys.exit(0 if __import__('importlib.util').find_spec('customtkinter') else 1)"
if %errorlevel% equ 0 (
python main.py
myenv\Scripts\python.exe main.py
) else (
python updater.py
myenv\Scripts\python.exe updater.py
)

0 comments on commit 52b1cbe

Please sign in to comment.