aboutsummaryrefslogtreecommitdiff
path: root/setup.sh
diff options
context:
space:
mode:
authorGravatar SwiftyOS <craigswift13@gmail.com> 2023-09-18 17:57:17 +0200
committerGravatar SwiftyOS <craigswift13@gmail.com> 2023-09-18 17:57:17 +0200
commit869682a87d603fc7bd5a19d34c5b399577217e11 (patch)
treec600ca725605a696a3ed1711a8e116e3c9391273 /setup.sh
parentAdded benchmarking to the quickstart (diff)
downloadAuto-GPT-869682a87d603fc7bd5a19d34c5b399577217e11.tar.gz
Auto-GPT-869682a87d603fc7bd5a19d34c5b399577217e11.tar.bz2
Auto-GPT-869682a87d603fc7bd5a19d34c5b399577217e11.zip
Added windows check in the setup script
Diffstat (limited to 'setup.sh')
-rwxr-xr-xsetup.sh40
1 files changed, 24 insertions, 16 deletions
diff --git a/setup.sh b/setup.sh
index f7020831e..0aba96b21 100755
--- a/setup.sh
+++ b/setup.sh
@@ -1,24 +1,32 @@
#!/bin/bash
-if ! command -v python3 &> /dev/null
-then
- echo "python3 could not be found"
- echo "Installing python3 using pyenv..."
- if ! command -v pyenv &> /dev/null
+if [[ "$OSTYPE" == "cygwin" ]] || [[ "$OSTYPE" == "msys" ]] || [[ "$OSTYPE" == "win32" ]]; then
+ echo "This script cannot be run on Windows."
+ echo "Please follow the installation instructions at https://docs.python.org/3/using/windows.html"
+ echo "To install poetry on Windows, please follow the instructions at https://python-poetry.org/docs/master/#installation"
+
+ exit 1
+else
+ if ! command -v python3 &> /dev/null
then
- echo "pyenv could not be found"
- echo "Installing pyenv..."
- curl https://pyenv.run | bash
+ echo "python3 could not be found"
+ echo "Installing python3 using pyenv..."
+ if ! command -v pyenv &> /dev/null
+ then
+ echo "pyenv could not be found"
+ echo "Installing pyenv..."
+ curl https://pyenv.run | bash
+ fi
+ pyenv install 3.11.5
+ pyenv global 3.11.5
fi
- pyenv install 3.11.5
- pyenv global 3.11.5
-fi
-if ! command -v poetry &> /dev/null
-then
- echo "poetry could not be found"
- echo "Installing poetry..."
- curl -sSL https://install.python-poetry.org | python3 -
+ if ! command -v poetry &> /dev/null
+ then
+ echo "poetry could not be found"
+ echo "Installing poetry..."
+ curl -sSL https://install.python-poetry.org | python3 -
+ fi
fi
if ! command -v flutter &> /dev/null