From 50d5bd72d5602fcefe5be53bc3849e7fe6f23a75 Mon Sep 17 00:00:00 2001 From: Pat Regan Date: Fri, 29 Apr 2011 22:45:53 -0400 Subject: [PATCH 1/5] Compile ~/.zcompdump if it has been updated --- oh-my-zsh.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/oh-my-zsh.sh b/oh-my-zsh.sh index 3ea88e924..c7d26c64f 100644 --- a/oh-my-zsh.sh +++ b/oh-my-zsh.sh @@ -39,6 +39,10 @@ else source "$ZSH/themes/$ZSH_THEME.zsh-theme" fi +# Compile zcompdump if necessary +if [ ~/.zcompdump -nt ~/.zcompdump.zwc ]; then + zcompile ~/.zcompdump +fi # Check for updates on initial load... if [ "$DISABLE_AUTO_UPDATE" = "true" ] From a4b53d90113e78d9afa873891662b068d06aefd6 Mon Sep 17 00:00:00 2001 From: Pat Regan Date: Sun, 1 May 2011 17:36:57 -0400 Subject: [PATCH 2/5] Quote paths --- oh-my-zsh.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/oh-my-zsh.sh b/oh-my-zsh.sh index c7d26c64f..5ba9deff4 100644 --- a/oh-my-zsh.sh +++ b/oh-my-zsh.sh @@ -40,7 +40,7 @@ else fi # Compile zcompdump if necessary -if [ ~/.zcompdump -nt ~/.zcompdump.zwc ]; then +if [ "~/.zcompdump" -nt "~/.zcompdump.zwc" ]; then zcompile ~/.zcompdump fi From ce0ac079006716840f535a7820f4b191f6e8b98c Mon Sep 17 00:00:00 2001 From: Pat Regan Date: Sun, 1 May 2011 17:47:56 -0400 Subject: [PATCH 3/5] Fixed a bug and quoting --- oh-my-zsh.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/oh-my-zsh.sh b/oh-my-zsh.sh index 5ba9deff4..3550c4302 100644 --- a/oh-my-zsh.sh +++ b/oh-my-zsh.sh @@ -40,8 +40,8 @@ else fi # Compile zcompdump if necessary -if [ "~/.zcompdump" -nt "~/.zcompdump.zwc" ]; then - zcompile ~/.zcompdump +if [ "~/.zcompdump -nt ~/.zcompdump.zwc" -o ! -e "~/.zcompdump.zwc" ]; then + zcompile "~/.zcompdump" fi # Check for updates on initial load... From b2638ef0c321ae8800449396b4edd8632938284b Mon Sep 17 00:00:00 2001 From: Pat Regan Date: Sun, 1 May 2011 17:50:29 -0400 Subject: [PATCH 4/5] zcompile seems to not like quoted pathnames... --- oh-my-zsh.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/oh-my-zsh.sh b/oh-my-zsh.sh index 3550c4302..45a2d7690 100644 --- a/oh-my-zsh.sh +++ b/oh-my-zsh.sh @@ -41,7 +41,7 @@ fi # Compile zcompdump if necessary if [ "~/.zcompdump -nt ~/.zcompdump.zwc" -o ! -e "~/.zcompdump.zwc" ]; then - zcompile "~/.zcompdump" + zcompile ~/.zcompdump fi # Check for updates on initial load... From d80b76380d0d0c768eb4317260200ae9295e6575 Mon Sep 17 00:00:00 2001 From: Pat Regan Date: Sun, 1 May 2011 19:24:03 -0400 Subject: [PATCH 5/5] Removed the quoting and fixed logic error --- oh-my-zsh.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/oh-my-zsh.sh b/oh-my-zsh.sh index 45a2d7690..b1508706e 100644 --- a/oh-my-zsh.sh +++ b/oh-my-zsh.sh @@ -40,7 +40,7 @@ else fi # Compile zcompdump if necessary -if [ "~/.zcompdump -nt ~/.zcompdump.zwc" -o ! -e "~/.zcompdump.zwc" ]; then +if [ ~/.zcompdump -nt ~/.zcompdump.zwc -o ! -e ~/.zcompdump.zwc ]; then zcompile ~/.zcompdump fi