2022-10-12 11:08:06 +00:00
|
|
|
#!/bin/bash
|
|
|
|
|
2022-10-14 03:26:27 +00:00
|
|
|
|
2022-10-12 11:08:06 +00:00
|
|
|
INSTALL_ENV_DIR="$(pwd)/installer_files/env"
|
2022-10-13 05:26:04 +00:00
|
|
|
if [ -e "$INSTALL_ENV_DIR" ]; then export PATH="$INSTALL_ENV_DIR/bin:$PATH"; fi
|
2022-10-12 11:08:06 +00:00
|
|
|
|
|
|
|
# update the repo
|
|
|
|
if [ -e ".git" ]; then
|
|
|
|
git pull
|
|
|
|
fi
|
2022-10-12 16:45:38 +00:00
|
|
|
|
2022-10-13 05:26:04 +00:00
|
|
|
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)
|
|
|
|
|
|
|
|
conda activate invokeai
|
|
|
|
|
2022-10-12 16:45:38 +00:00
|
|
|
OS_NAME=$(uname -s)
|
|
|
|
case "${OS_NAME}" in
|
|
|
|
Linux*) conda env update;;
|
|
|
|
Darwin*) conda env update -f environment-mac.yml;;
|
|
|
|
*) echo "Unknown OS: $OS_NAME! This script runs only on Linux or Mac" && exit
|
|
|
|
esac
|
2022-11-02 19:26:02 +00:00
|
|
|
|
|
|
|
python scripts/preload_models.py
|
2022-11-09 20:16:57 +00:00
|
|
|
|
|
|
|
|