mirror of
https://github.com/rangermix/TwitchDropsMiner.git
synced 2026-05-26 07:08:04 +00:00
Fix reviews
This commit is contained in:
20
build.bat
20
build.bat
@@ -13,25 +13,39 @@ if not exist "%dirpath%\env" (
|
||||
exit /b 1
|
||||
)
|
||||
|
||||
REM Check if pyinstaller and pywin32 is installed in the virtual environment
|
||||
REM Check if PyInstaller and pywin32 is installed in the virtual environment
|
||||
if not exist "%dirpath%\env\scripts\pyinstaller.exe" (
|
||||
echo Installing PyInstaller...
|
||||
"%dirpath%\env\scripts\pip" install pyinstaller
|
||||
if errorlevel 1 (
|
||||
echo Failed to install pyinstaller.
|
||||
echo:
|
||||
echo Failed to install PyInstaller.
|
||||
echo:
|
||||
pause
|
||||
exit /b 1
|
||||
)
|
||||
"%dirpath%\env\scripts\python" "%dirpath%\env\scripts\pywin32_postinstall.py" -install -silent
|
||||
if errorlevel 1 (
|
||||
echo:
|
||||
echo Failed to run pywin32_postinstall.py.
|
||||
echo:
|
||||
pause
|
||||
exit /b 1
|
||||
)
|
||||
)
|
||||
|
||||
REM Run pyinstaller with the specified build spec file
|
||||
REM Run PyInstaller with the specified build spec file
|
||||
echo Building...
|
||||
"%dirpath%\env\scripts\pyinstaller" "%dirpath%\build.spec"
|
||||
if errorlevel 1 (
|
||||
echo:
|
||||
echo PyInstaller build failed.
|
||||
echo:
|
||||
pause
|
||||
exit /b 1
|
||||
)
|
||||
|
||||
echo:
|
||||
echo Build completed successfully.
|
||||
echo:
|
||||
pause
|
||||
|
||||
17
build.sh
17
build.sh
@@ -11,26 +11,33 @@ if [ ! -d "$dirpath/env" ]; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Check if pyinstaller is installed in the virtual environment
|
||||
# Check if PyInstaller is installed in the virtual environment
|
||||
if [ ! -f "$dirpath/env/bin/pyinstaller" ]; then
|
||||
echo
|
||||
echo "Installing pyinstaller..."
|
||||
echo "Installing PyInstaller..."
|
||||
"$dirpath/env/bin/pip" install pyinstaller
|
||||
if [ $? -ne 0 ]; then
|
||||
echo "Failed to install pyinstaller."
|
||||
echo
|
||||
echo "Failed to install PyInstaller."
|
||||
echo
|
||||
read -p "Press any key to continue..."
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
|
||||
# Run pyinstaller with the specified build spec file
|
||||
# Run PyInstaller with the specified build spec file
|
||||
echo
|
||||
echo "Running pyinstaller..."
|
||||
echo "Running PyInstaller..."
|
||||
"$dirpath/env/bin/pyinstaller" "$dirpath/build.spec"
|
||||
if [ $? -ne 0 ]; then
|
||||
echo
|
||||
echo "PyInstaller build failed."
|
||||
echo
|
||||
read -p "Press any key to continue..."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo
|
||||
echo "Build completed successfully."
|
||||
echo
|
||||
read -p "Press any key to continue..."
|
||||
|
||||
@@ -7,6 +7,7 @@ if "%dirpath:~-1%" == "\" set "dirpath=%dirpath:~0,-1%"
|
||||
REM Check if git is installed
|
||||
git --version > nul 2>&1
|
||||
if %errorlevel% NEQ 0 (
|
||||
echo:
|
||||
echo No git executable found in PATH!
|
||||
echo:
|
||||
pause
|
||||
@@ -31,16 +32,17 @@ REM Activate the virtual environment and install requirements
|
||||
echo:
|
||||
echo Installing requirements.txt...
|
||||
"%dirpath%\env\scripts\python" -m pip install -U pip
|
||||
|
||||
"%dirpath%\env\scripts\pip" install wheel
|
||||
|
||||
"%dirpath%\env\scripts\pip" install -r "%dirpath%\requirements.txt"
|
||||
if %errorlevel% NEQ 0 (
|
||||
echo:
|
||||
echo Failed to install requirements.
|
||||
echo:
|
||||
pause
|
||||
exit /b 1
|
||||
)
|
||||
|
||||
echo:
|
||||
echo All done!
|
||||
echo Environment setup completed successfully.
|
||||
echo:
|
||||
pause
|
||||
|
||||
@@ -4,6 +4,7 @@ dirpath=$(dirname "$(readlink -f "$0")")
|
||||
|
||||
# Check if git is installed
|
||||
if ! command -v git &> /dev/null; then
|
||||
echo
|
||||
echo "No git executable found in PATH!"
|
||||
echo
|
||||
read -p "Press any key to continue..."
|
||||
@@ -28,16 +29,17 @@ fi
|
||||
echo
|
||||
echo "Installing requirements.txt..."
|
||||
"$dirpath/env/bin/python" -m pip install -U pip
|
||||
|
||||
"$dirpath/env/bin/pip" install wheel
|
||||
|
||||
"$dirpath/env/bin/pip" install -r "$dirpath/requirements.txt"
|
||||
if [ $? -ne 0 ]; then
|
||||
echo
|
||||
echo "Failed to install requirements."
|
||||
echo
|
||||
read -p "Press any key to continue..."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo
|
||||
echo "All done!"
|
||||
echo "Environment setup completed successfully."
|
||||
echo
|
||||
read -p "Press any key to continue..."
|
||||
|
||||
Reference in New Issue
Block a user