diff options
| author | ruki <[email protected]> | 2016-07-02 15:27:00 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2016-07-02 15:27:00 +0800 |
| commit | af3465afb3f509904099170b986f46937784b3e5 (patch) | |
| tree | 0c126f336fc1c13ce85043db0df3e4c96135802e | |
| parent | ce13439bc03a2284975f0a8da56bba571798b39d (diff) | |
improve install script for
| -rwxr-xr-x | install | 9 |
1 files changed, 7 insertions, 2 deletions
@@ -8,9 +8,9 @@ verbose= #verbose=-v # prefix -if [ -d "/usr/local" ]; then +if [[ "$PATH" =~ "/usr/local/bin" ]]; then prefix=/usr/local -elif [ -d "/usr" ]; then +else prefix=/usr fi if [ $1 ]; then @@ -115,5 +115,10 @@ if [ $? -ne 0 ]; then exit; fi +# tip +if [[ ! "$PATH" =~ "$prefix/bin" ]]; then + echo 'please export PATH=$PATH:'"$prefix/bin" +fi + # ok echo ok! |
