604f580f0546aefd6aef00b1a1943d68f4cebae6

Author
Sean Abraham <Sean.A208@gmail.com>
Committer
Marc Cornellà <marc.cornella@live.com>
Date

Message

Make steeef theme much faster by not iterating through all history (#6359)

* Make steef much faster by not printing all history each time

* Use whence -c to expand shell functions as well

* Use $2 (expanded command about to be ran)

Diff

 1diff --git a/themes/steeef.zsh-theme b/themes/steeef.zsh-theme
 2index b72a41c92262b9d04cc3302b4e6e73852c6c6802..88ef1ca1b71bb5a05575e4c04208ac7d3d6b80cf 100644
 3--- a/themes/steeef.zsh-theme
 4+++ b/themes/steeef.zsh-theme
 5@@ -62,7 +62,7 @@ zstyle ':vcs_info:*:prompt:*' nvcsformats   ""
 6 
 7 
 8 function steeef_preexec {
 9-    case "$(history $HISTCMD)" in
10+    case "$2" in
11         *git*)
12             PR_GIT_UPDATE=1
13             ;;