mirror of
https://github.com/Cog-Creators/Red-DiscordBot.git
synced 2025-11-20 18:06:08 -05:00
Make files - fallback to python(3.8) from PATH if .venv doesn't exist (#4863)
This commit is contained in:
12
make.bat
12
make.bat
@@ -2,18 +2,24 @@
|
||||
|
||||
if [%1] == [] goto help
|
||||
|
||||
if exist "%~dp0.venv\" (
|
||||
set "VENV_PYTHON=%~dp0.venv\Scripts\python"
|
||||
) else (
|
||||
set VENV_PYTHON=python
|
||||
)
|
||||
|
||||
goto %1
|
||||
|
||||
:reformat
|
||||
"%~dp0.venv\Scripts\black" "%~dp0."
|
||||
"%VENV_PYTHON%" -m black "%~dp0."
|
||||
goto:eof
|
||||
|
||||
:stylecheck
|
||||
"%~dp0.venv\Scripts\black" --check "%~dp0."
|
||||
"%VENV_PYTHON%" -m black --check "%~dp0."
|
||||
goto:eof
|
||||
|
||||
:stylediff
|
||||
"%~dp0.venv\Scripts\black" --check --diff "%~dp0."
|
||||
"%VENV_PYTHON%" -m black --check --diff "%~dp0."
|
||||
goto:eof
|
||||
|
||||
:newenv
|
||||
|
||||
Reference in New Issue
Block a user