about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog6
-rw-r--r--Completion/Commands/_history_complete_word5
-rw-r--r--Completion/Core/_expand2
-rw-r--r--Completion/Core/_history5
4 files changed, 18 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index f2d6fbee2..727561b7c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2000-06-21  Sven Wischnowsky  <wischnow@zsh.org>
+
+	* 12011: Completion/Commands/_history_complete_word,
+ 	Completion/Core/_expand, Completion/Core/_history: make history
+ 	completion use I{PREF,SUF}FIX
+	
 2000-06-20  Oliver Kiddle  <opk@zsh.org>
 
 	* unposted: Src/exec.c: AIX dependency fix
diff --git a/Completion/Commands/_history_complete_word b/Completion/Commands/_history_complete_word
index 00d7ba369..300100f59 100644
--- a/Completion/Commands/_history_complete_word
+++ b/Completion/Commands/_history_complete_word
@@ -85,6 +85,11 @@ _history_complete_word_gen_matches () {
     opt="${opt}V"
   fi
 
+  PREFIX="$IPREFIX$PREFIX"
+  IPREFIX=
+  SUFFIX="$SUFFIX$ISUFFIX"
+  ISUFFIX=
+
   h_words=( "${(@)historywords[2,-1]}" )
   _wanted "$opt" history-words expl 'history word' \
       compadd -Q -a h_words
diff --git a/Completion/Core/_expand b/Completion/Core/_expand
index 8b0bae95f..6ebbfa042 100644
--- a/Completion/Core/_expand
+++ b/Completion/Core/_expand
@@ -33,6 +33,8 @@ else
   word="$IPREFIX$PREFIX$SUFFIX$ISUFFIX"
 fi
 
+[[ "$word" = *\$\{[^\}]# ]] && return 1
+
 zstyle -T ":completion:${curcontext}:" suffix &&
   [[ "$word" = (\~*/*|\$[a-zA-Z0-9_\[\]]##[^a-zA-Z0-9_\[\]]*|\$\{*\}?*) ]] &&
   return 1
diff --git a/Completion/Core/_history b/Completion/Core/_history
index 86fd9efc5..109bda91f 100644
--- a/Completion/Core/_history
+++ b/Completion/Core/_history
@@ -30,6 +30,11 @@ else
   opt="${opt}V"
 fi
 
+PREFIX="$IPREFIX$PREFIX"
+IPREFIX=
+SUFFIX="$SUFFIX$ISUFFIX"
+ISUFFIX=
+
 # We skip the first element of historywords so the current word doesn't
 # interfere with the completion
 h_words=( "${(@)historywords[2,-1]}" )