1
0
mirror of https://github.com/fumiama/Retrieval-based-Voice-Conversion-WebUI.git synced 2026-06-05 01:10:22 +08:00
Files
Alex Murkoff f79b925ee2 refactor(scripts): simplify run.sh script (#48)
* refactor(scripts): simplify run.sh script

a lot of the contents of run.sh is either wrong, unnecessary, or both! a program runner-script that installs software on your PC is a terrible idea, since users themselves should make such decisions, not some random installer/runner scripts from a github repo. the overfixation on python3.8 makes this script practically entirely useless on any linux system that isn't based on debian, or is based on debian but is heavily modified. on archlinux this script is useless, it wont install anything for you and it wont find python3.8 since there's no such thing as python3.8 ANYWHERE except for a few distros where older versions of software are not stored in an archive, but rather in the packages repo

* refactor(scripts): apply a lot more of refactoring of run script

* fix(scripts): remove env variable setting for macOS systems

use --pycmd python instead of --pycmd python3
2024-06-13 23:52:49 +09:00

28 lines
588 B
Bash
Executable File

#!/bin/sh
set -fa
# Check if Python is installed
if ! command -v python; then
echo "Python not found. Please install Python using your package manager or via PyEnv."
exit 1
fi
requirements_file="requirements/main.txt"
venv_path=".venv"
if [[ ! -d "${venv_path}" ]]; then
echo "Creating venv..."
python -m venv "${venv_path}"
source "${venv_path}/bin/activate"
# Check if required packages are up-to-date
pip install --upgrade -r "${requirements_file}"
fi
echo "Activating venv..."
source "${venv_path}/bin/activate"
# Run the main script
python web.py --pycmd python