Skip to content

Commit

Permalink
Merge pull request ChatGPTNextWeb#979 from jzjwonderful/bug-978
Browse files Browse the repository at this point in the history
[Bug] Unsupported Linux distribution when running setup.sh on Ubuntu OS
  • Loading branch information
Yidadaa authored Apr 21, 2023
2 parents 0b36daf + 596a468 commit d053bee
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions scripts/setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,13 +29,13 @@ esac
if ! command -v node >/dev/null || ! command -v git >/dev/null || ! command -v yarn >/dev/null; then
case "$(uname -s)" in
Linux)
if [[ "$(cat /etc/*-release | grep '^ID=')" = "ID=\"ubuntu\"" ]]; then
if [[ "$(cat /etc/*-release | grep '^ID=')" = "ID=ubuntu" ]]; then
sudo apt-get update
sudo apt-get -y install nodejs git yarn
elif [[ "$(cat /etc/*-release | grep '^ID=')" = "ID=\"centos\"" ]]; then
elif [[ "$(cat /etc/*-release | grep '^ID=')" = "ID=centos" ]]; then
sudo yum -y install epel-release
sudo yum -y install nodejs git yarn
elif [[ "$(cat /etc/*-release | grep '^ID=')" = "ID=\"arch\"" ]]; then
elif [[ "$(cat /etc/*-release | grep '^ID=')" = "ID=arch" ]]; then
sudo pacman -Syu -y
sudo pacman -S -y nodejs git yarn
else
Expand Down

0 comments on commit d053bee

Please sign in to comment.