From 7e398391dbd11a1974c8b35913d268853a8a21be Mon Sep 17 00:00:00 2001 From: Andrew Janke Date: Tue, 7 Jul 2015 16:48:05 -0400 Subject: history-substring-search: update to upstream version 2015-09-28 Updates OMZ's copy to commit 2c295432175990c1bb4e90bc13f609daa67a25d6 from zsh-users/zsh-history-substring-search --- .../history-substring-search.plugin.zsh | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) (limited to 'plugins/history-substring-search/history-substring-search.plugin.zsh') diff --git a/plugins/history-substring-search/history-substring-search.plugin.zsh b/plugins/history-substring-search/history-substring-search.plugin.zsh index 99a5922c5..25fd3a2da 100644 --- a/plugins/history-substring-search/history-substring-search.plugin.zsh +++ b/plugins/history-substring-search/history-substring-search.plugin.zsh @@ -1,6 +1,6 @@ -# This file integrates the history-substring-search script into oh-my-zsh. +# This file integrates the zsh-history-substring-search script into oh-my-zsh. -source "$ZSH/plugins/history-substring-search/history-substring-search.zsh" +source "${0:r:r}.zsh" if test "$CASE_SENSITIVE" = true; then unset HISTORY_SUBSTRING_SEARCH_GLOBBING_FLAGS @@ -10,3 +10,14 @@ if test "$DISABLE_COLOR" = true; then unset HISTORY_SUBSTRING_SEARCH_HIGHLIGHT_FOUND unset HISTORY_SUBSTRING_SEARCH_HIGHLIGHT_NOT_FOUND fi + + +# Bind terminal-specific up and down keys + +if [[ -n "$terminfo[kcuu1]" ]]; then + bindkey "$terminfo[kcuu1]" history-substring-search-up +fi +if [[ -n "$terminfo[kcud1]" ]]; then + bindkey "$terminfo[kcud1]" history-substring-search-down +fi + -- cgit v1.2.3-70-g09d2