summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.zshrc6
1 files changed, 5 insertions, 1 deletions
diff --git a/.zshrc b/.zshrc
index a5154e2..db476dd 100644
--- a/.zshrc
+++ b/.zshrc
@@ -451,7 +451,11 @@ cat-history-notime() {
}
hgrep() {
- cat-history | mpgrep "$@" | less
+ if type mpgrep &>/dev/null; then
+ cat-history | mpgrep "$@" | less
+ else
+ cat-history | grep "$@" | less
+ fi
}
cd-pkg() {