mirror of
https://github.com/easydiffusion/easydiffusion.git
synced 2024-12-26 00:49:17 +01:00
Activate the installer env while starting up, like the previous installer did in the start script
This commit is contained in:
parent
a281efef04
commit
0c2d227da1
@ -11,6 +11,9 @@ call scripts\bootstrap.bat
|
||||
@rem set new installer's PATH, if it downloaded any packages
|
||||
if exist "installer_files\env" set PATH=%cd%\installer_files\env;%cd%\installer_files\env\Library\bin;%cd%\installer_files\env\Scripts;%cd%\installer_files\Library\usr\bin;%PATH%
|
||||
|
||||
@rem activate the installer env
|
||||
conda activate
|
||||
|
||||
@rem Test the bootstrap
|
||||
call where git
|
||||
call git --version
|
||||
|
@ -68,10 +68,6 @@ if exist "%cd%\profile" (
|
||||
set TMP=%cd%\tmp
|
||||
set TEMP=%cd%\tmp
|
||||
|
||||
@REM deactivate any pre-activated conda environments, by returning to (base) and then deactivating that
|
||||
call conda activate
|
||||
call conda deactivate
|
||||
|
||||
@call conda env create --prefix env -f environment.yaml || (
|
||||
@echo. & echo "Error installing the packages necessary for Stable Diffusion. Sorry about that, please try to:" & echo " 1. Run this installer again." & echo " 2. If that doesn't fix it, please try the common troubleshooting steps at https://github.com/cmdr2/stable-diffusion-ui/wiki/Troubleshooting" & echo " 3. If those steps don't help, please copy *all* the error messages in this window, and ask the community at https://discord.com/invite/u9yhsFmEkB" & echo " 4. If that doesn't solve the problem, please file an issue at https://github.com/cmdr2/stable-diffusion-ui/issues" & echo "Thanks!" & echo.
|
||||
pause
|
||||
|
@ -3,9 +3,6 @@
|
||||
cp sd-ui-files/scripts/on_env_start.sh scripts/
|
||||
cp sd-ui-files/scripts/bootstrap.sh scripts/
|
||||
|
||||
CONDA_BASEPATH=$(conda info --base)
|
||||
source "$CONDA_BASEPATH/etc/profile.d/conda.sh" # otherwise conda complains about 'shell not initialized' (needed when running in a script)
|
||||
|
||||
# remove the old version of the dev console script, if it's still present
|
||||
if [ -e "open_dev_console.sh" ]; then
|
||||
rm "open_dev_console.sh"
|
||||
@ -62,10 +59,6 @@ else
|
||||
# prevent conda from using packages from the user's home directory, to avoid conflicts
|
||||
export PYTHONNOUSERSITE=1
|
||||
|
||||
# deactivate any pre-activated conda environments, by returning to (base) and then deactivating that
|
||||
conda activate
|
||||
conda deactivate
|
||||
|
||||
if conda env create --prefix env --force -f environment.yaml ; then
|
||||
echo "Installed. Testing.."
|
||||
else
|
||||
|
@ -9,6 +9,12 @@ scripts/bootstrap.sh
|
||||
# set new installer's PATH, if it downloaded any packages
|
||||
if [ -e "installer_files/env" ]; then export PATH="$(pwd)/installer_files/env/bin:$PATH"; fi
|
||||
|
||||
# activate the installer env
|
||||
CONDA_BASEPATH=$(conda info --base)
|
||||
source "$CONDA_BASEPATH/etc/profile.d/conda.sh" # avoids the 'shell not initialized' error
|
||||
|
||||
conda activate
|
||||
|
||||
# Test the bootstrap
|
||||
which git
|
||||
git --version
|
||||
|
Loading…
Reference in New Issue
Block a user