From 5659e7cce90c6b01f717f65089ea86eafd2dc3c3 Mon Sep 17 00:00:00 2001 From: Bob131 Date: Mon, 27 Jul 2015 17:54:42 +1000 Subject: [PATCH] Fix install.sh for non-GNU sed Removed -i option from sed invocations for enhanced compatibility with eg BSD sed --- tools/install.sh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tools/install.sh b/tools/install.sh index c83a6f23d..8bfc023eb 100755 --- a/tools/install.sh +++ b/tools/install.sh @@ -23,14 +23,14 @@ 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\\ +cat ~/.zshrc | sed -e "/^export ZSH=/ c\\ export ZSH=$ZSH -" ~/.zshrc +" > ~/.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\\ +cat ~/.zshrc | sed -e "/export PATH=/ c\\ export PATH=\"$PATH\" -" ~/.zshrc +" > ~/.zshrc TEST_CURRENT_SHELL=$(expr "$SHELL" : '.*/\(.*\)') if [ "$TEST_CURRENT_SHELL" != "zsh" ]; then