diff options
author | Robby Russell <robby@planetargon.com> | 2015-08-30 09:13:04 -0700 |
---|---|---|
committer | Robby Russell <robby@planetargon.com> | 2015-08-30 09:13:04 -0700 |
commit | b3f167d998580d4017a16c23c233925a5cb7afb0 (patch) | |
tree | 660440774a79e13dfdd19bd218745d8df51622cd /tools | |
parent | a7aed69d02e204f4b724c73f1dfbce41edd9ea5d (diff) | |
parent | 1246c3e08bfb7d999bac2ae3e9933084cffbc4eb (diff) | |
download | zsh-b3f167d998580d4017a16c23c233925a5cb7afb0.tar.gz zsh-b3f167d998580d4017a16c23c233925a5cb7afb0.tar.bz2 zsh-b3f167d998580d4017a16c23c233925a5cb7afb0.zip |
Merge pull request #3613 from apjanke/remove-sed-i
Installer: Remove "sed -i" for portability and hygiene
Diffstat (limited to 'tools')
-rwxr-xr-x | tools/install.sh | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/tools/install.sh b/tools/install.sh index c83a6f23d..17f4076c1 100755 --- a/tools/install.sh +++ b/tools/install.sh @@ -23,14 +23,16 @@ fi echo "\033[0;34mUsing the Oh My Zsh template file and adding it to ~/.zshrc\033[0m" cp $ZSH/templates/zshrc.zsh-template ~/.zshrc -sed -i -e "/^export ZSH=/ c\\ +sed "/^export ZSH=/ c\\ export ZSH=$ZSH -" ~/.zshrc +" ~/.zshrc > ~/.zshrc-omztemp +mv -f ~/.zshrc-omztemp ~/.zshrc echo "\033[0;34mCopying your current PATH and adding it to the end of ~/.zshrc for you.\033[0m" -sed -i -e "/export PATH=/ c\\ +sed "/export PATH=/ c\\ export PATH=\"$PATH\" -" ~/.zshrc +" ~/.zshrc > ~/.zshrc-omztemp +mv -f ~/.zshrc-omztemp ~/.zshrc TEST_CURRENT_SHELL=$(expr "$SHELL" : '.*/\(.*\)') if [ "$TEST_CURRENT_SHELL" != "zsh" ]; then |