Commit 54db523c2839751f08f9104d08d4001fd123a4df
1 parent
d979879096
Exists in
master
and in
2 other branches
FIX install.sh
Showing 1 changed file with 4 additions and 2 deletions Side-by-side Diff
tools/install.sh
| ... | ... | @@ -12,13 +12,15 @@ |
| 12 | 12 | |
| 13 | 13 | set -e |
| 14 | 14 | |
| 15 | +if [ $UID -eq 0 ]; then CMD_PREFIX="sudo"; else CMD_PREFIX=""; fi | |
| 16 | + | |
| 15 | 17 | if [ "$SHELL" != "$(which zsh)" ]; then |
| 16 | 18 | echo "$(which zsh)" |
| 17 | - sudo echo "enter pass...." | |
| 19 | + $CMD_PREFIX echo "enter pass...." | |
| 18 | 20 | |
| 19 | 21 | echo "ok" |
| 20 | 22 | |
| 21 | - sudo apt-get -yq install curl dialog git nano zsh | |
| 23 | + $CMD_PREFIX apt-get -yq install curl dialog git nano zsh | |
| 22 | 24 | fi |
| 23 | 25 | |
| 24 | 26 | if [ 1 == 2 ]; then |