Browse code

Removed unportable (and unnecessary) grep flags

Matt Cable authored on 21/09/2010 at 18:07:02
Showing 1 changed files
... ...
@@ -9,7 +9,7 @@
9 9
 zdirstore=~/.zdirstore
10 10
 
11 11
 dirpersistinstall () {
12
-    if grep -qL 'dirpersiststore' ~/.zlogout; then
12
+    if grep 'dirpersiststore' ~/.zlogout > /dev/null; then
13 13
     else
14 14
         if read -q \?"Would you like to set up your .zlogout file for use with dirspersist? (y/n) "; then
15 15
             echo "# Store dirs stack\n# See ~/.oh-my-zsh/plugins/dirspersist.plugin.zsh\ndirpersiststore" >> ~/.zlogout
... ...
@@ -19,6 +19,7 @@ dirpersistinstall () {
19 19
     fi
20 20
 }
21 21
 
22
+# FIXME solaris doesn't support tail -r
22 23
 dirpersiststore () {
23 24
     dirs -p | tail -r | perl -ne 'chomp;s/([& ])/\\$1/g ;print "if [ -d $_ ]; then pushd -q $_; fi\n"' > $zdirstore
24 25
 }