From 6c5f81f002dba4da623e64f89efc218d28d61185 Mon Sep 17 00:00:00 2001 From: oobabooga <112222186+oobabooga@users.noreply.github.com> Date: Fri, 22 Sep 2023 12:00:06 -0700 Subject: [PATCH] Rename webui.py to one_click.py --- README.md | 2 +- webui.py => one_click.py | 0 start_linux.sh | 2 +- start_macos.sh | 2 +- start_windows.bat | 2 +- update_linux.sh | 2 +- update_macos.sh | 2 +- update_windows.bat | 2 +- wsl.sh | 14 +++++++------- 9 files changed, 14 insertions(+), 14 deletions(-) rename webui.py => one_click.py (100%) diff --git a/README.md b/README.md index b90d04cd..a65c170f 100644 --- a/README.md +++ b/README.md @@ -51,7 +51,7 @@ Some observations: * There is no need to run any of those scripts as admin/root. * If you need to move your installation folder, you will need to delete `installer_files` and install again, as some links will be broken. So choose a good location for your `text-generation-webui` folder before installing. * Additional instructions for WSL and AMD users can be found here: [Instructions](https://github.com/oobabooga/text-generation-webui/blob/one-click/docs/new/Installation%20Instructions.md). -* The installer has been tested mostly on NVIDIA GPUs. If you can find a way to improve it for your AMD/Intel Arc/Mac Metal GPU, you are highly encouraged to submit a PR to this repository. +* The installer has been tested mostly on NVIDIA GPUs. If you can find a way to improve it for your AMD/Intel Arc/Mac Metal GPU, you are highly encouraged to submit a PR to this repository. The main file to be edited is `one_click.py`. ### Manual installation using Conda diff --git a/webui.py b/one_click.py similarity index 100% rename from webui.py rename to one_click.py diff --git a/start_linux.sh b/start_linux.sh index 6792902a..d9d2ab07 100755 --- a/start_linux.sh +++ b/start_linux.sh @@ -64,4 +64,4 @@ source "$CONDA_ROOT_PREFIX/etc/profile.d/conda.sh" # otherwise conda complains a conda activate "$INSTALL_ENV_DIR" # setup installer env -python webui.py $@ +python one_click.py $@ diff --git a/start_macos.sh b/start_macos.sh index 5f5bb439..7fa82d81 100755 --- a/start_macos.sh +++ b/start_macos.sh @@ -64,4 +64,4 @@ source "$CONDA_ROOT_PREFIX/etc/profile.d/conda.sh" # otherwise conda complains a conda activate "$INSTALL_ENV_DIR" # setup installer env -python webui.py $@ +python one_click.py $@ diff --git a/start_windows.bat b/start_windows.bat index c75708ab..da8050f0 100755 --- a/start_windows.bat +++ b/start_windows.bat @@ -67,7 +67,7 @@ set "CUDA_HOME=%CUDA_PATH%" call "%CONDA_ROOT_PREFIX%\condabin\conda.bat" activate "%INSTALL_ENV_DIR%" || ( echo. && echo Miniconda hook not found. && goto end ) @rem setup installer env -call python webui.py %* +call python one_click.py %* @rem below are functions for the script next line skips these during normal execution goto end diff --git a/update_linux.sh b/update_linux.sh index e641fafb..28686b0f 100755 --- a/update_linux.sh +++ b/update_linux.sh @@ -23,7 +23,7 @@ source "$CONDA_ROOT_PREFIX/etc/profile.d/conda.sh" # otherwise conda complains a conda activate "$INSTALL_ENV_DIR" # update installer env -python webui.py --update +python one_click.py --update echo echo "Done!" diff --git a/update_macos.sh b/update_macos.sh index e641fafb..28686b0f 100755 --- a/update_macos.sh +++ b/update_macos.sh @@ -23,7 +23,7 @@ source "$CONDA_ROOT_PREFIX/etc/profile.d/conda.sh" # otherwise conda complains a conda activate "$INSTALL_ENV_DIR" # update installer env -python webui.py --update +python one_click.py --update echo echo "Done!" diff --git a/update_windows.bat b/update_windows.bat index 944ec32b..b08773cf 100755 --- a/update_windows.bat +++ b/update_windows.bat @@ -28,7 +28,7 @@ set "CUDA_HOME=%CUDA_PATH%" call "%CONDA_ROOT_PREFIX%\condabin\conda.bat" activate "%INSTALL_ENV_DIR%" || ( echo. && echo Miniconda hook not found. && goto end ) @rem update installer env -call python webui.py --update +call python one_click.py --update echo. echo Done! diff --git a/wsl.sh b/wsl.sh index 6b62adca..4ff72c04 100755 --- a/wsl.sh +++ b/wsl.sh @@ -47,9 +47,9 @@ fi if [[ "$INSTALL_DIR" =~ " " ]]; then echo This script relies on Miniconda which can not be silently installed under a path with spaces. && exit; fi -# create install dir if missing and copy webui.py to install dir to maintain functionality without edit +# create install dir if missing and copy one_click.py to install dir to maintain functionality without edit if [ ! -d "$INSTALL_DIR" ]; then mkdir -p "$INSTALL_DIR" || exit; fi -cp -u "./webui.py" "$INSTALL_DIR" +cp -u "./one_click.py" "$INSTALL_DIR" if [ -f "./CMD_FLAGS.txt" ]; then cp -u "./CMD_FLAGS.txt" "$INSTALL_DIR"; fi # figure out whether git and conda needs to be installed @@ -85,9 +85,9 @@ fi source "$CONDA_ROOT_PREFIX/etc/profile.d/conda.sh" # otherwise conda complains about 'shell not initialized' (needed when running in a script) conda activate "$INSTALL_ENV_DIR" -# copy webui.py and CMD_FLAGS.txt to install dir to allow edits within Windows +# copy one_click.py and CMD_FLAGS.txt to install dir to allow edits within Windows if [[ $INSTALL_INPLACE != 1 ]]; then - cp -u "./webui.py" "$INSTALL_DIR" + cp -u "./one_click.py" "$INSTALL_DIR" if [ -f "./CMD_FLAGS.txt" ]; then cp -u "./CMD_FLAGS.txt" "$INSTALL_DIR"; fi fi @@ -100,11 +100,11 @@ if [ ! -f "./server.py" ]; then git remote set-head origin -a git reset origin/HEAD --hard git branch --set-upstream-to=origin/HEAD - git restore -- . :!./webui.py :!./CMD_FLAGS.txt + git restore -- . :!./one_click.py :!./CMD_FLAGS.txt fi # setup installer env update env if called with 'wsl.sh update' case "$1" in -("update") python webui.py --update;; -(*) python webui.py $@;; +("update") python one_click.py --update;; +(*) python one_click.py $@;; esac