* Re: PATCH: Corrected style test in prediction
@ 2000-02-23 15:53 Sven Wischnowsky
0 siblings, 0 replies; 5+ messages in thread
From: Sven Wischnowsky @ 2000-02-23 15:53 UTC (permalink / raw)
To: zsh-workers
I wrote:
> - curcontext="${curcontext#*:}predict:"
> + curcontext="predict:${curcontext#*:}"
Getting a bit slow in the brain...
Bye
Sven
diff -ru ../z.old/Functions/Zle/incremental-complete-word Functions/Zle/incremental-complete-word
--- ../z.old/Functions/Zle/incremental-complete-word Wed Feb 23 14:44:05 2000
+++ Functions/Zle/incremental-complete-word Wed Feb 23 16:52:31 2000
@@ -21,7 +21,7 @@
local curcontext="${curcontext}" stop brk
[[ -z "$curcontext" ]] && curcontext=:::
- curcontext="${curcontext#*:}incremental:"
+ curcontext="incremental:${curcontext#*:}"
zstyle -s ":completion:${curcontext}" prompt pmpt ||
pmpt='incremental (%c): %u%s %l'
--
Sven Wischnowsky wischnow@informatik.hu-berlin.de
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: PATCH: Corrected style test in prediction
@ 2000-02-23 15:48 Sven Wischnowsky
0 siblings, 0 replies; 5+ messages in thread
From: Sven Wischnowsky @ 2000-02-23 15:48 UTC (permalink / raw)
To: zsh-workers
Bart Schaefer wrote:
> } The number of colons is still correct, but the original context name
> } was correct, too. The `predict' was stored in the `function' field of
> } the context name, indicating that completion was called from predict.
>
> But in insert-and-predict we have:
>
> local crs curcontext="${curcontext}"
>
> [[ -z "$curcontext" ]] && curcontext=:::
> curcontext="${curcontext#*:}predict:"
>
> which makes the context be :completion:::predict::, with `predict' in
> the `command' field. Surely the two should be the same? If not, why
> not?
Ouch. Thanks for the hint.
Bye
Sven
diff -ru ../z.old/Functions/Zle/predict-on Functions/Zle/predict-on
--- ../z.old/Functions/Zle/predict-on Wed Feb 23 14:44:05 2000
+++ Functions/Zle/predict-on Wed Feb 23 16:47:41 2000
@@ -56,7 +56,7 @@
local crs curcontext="${curcontext}"
[[ -z "$curcontext" ]] && curcontext=:::
- curcontext="${curcontext#*:}predict:"
+ curcontext="predict:${curcontext#*:}"
comppostfuncs=( predict-limit-list )
zle complete-word
--
Sven Wischnowsky wischnow@informatik.hu-berlin.de
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: PATCH: Corrected style test in prediction
@ 2000-02-23 10:46 Sven Wischnowsky
2000-02-23 15:42 ` Bart Schaefer
0 siblings, 1 reply; 5+ messages in thread
From: Sven Wischnowsky @ 2000-02-23 10:46 UTC (permalink / raw)
To: zsh-workers
Bart Schaefer wrote:
> Sven, please confirm ... I'm never sure about the number of trailing colons.
>
> Index: Functions/Zle/predict-on
> ===================================================================
> @@ -122,7 +122,7 @@
> then
> compstate[list]=''
> compstate[force_list]=yes
> - elif zstyle -t ":completion:predict::::" list always
> + elif zstyle -t ":completion:::predict::" list always
> then
> compstate[force_list]=yes
> fi
The number of colons is still correct, but the original context name
was correct, too. The `predict' was stored in the `function' field of
the context name, indicating that completion was called from predict.
However, the other call to zstyle had a missing colon, the one before
the (not-given) tag.
The patch also fixes a type in _gunzip -- as shown in Peter's guide.
Bye
Sven
diff -ru ../z.old/Completion/User/_gunzip Completion/User/_gunzip
--- ../z.old/Completion/User/_gunzip Wed Feb 23 10:37:24 2000
+++ Completion/User/_gunzip Wed Feb 23 11:20:56 2000
@@ -3,4 +3,4 @@
local expl
_description files expl 'compressed file'
-_files "$expl[@]" -g '*.([tT]|)[gG][z]'
+_files "$expl[@]" -g '*.([tT]|)[gG][zZ]'
diff -ru ../z.old/Functions/Zle/predict-on Functions/Zle/predict-on
--- ../z.old/Functions/Zle/predict-on Wed Feb 23 09:03:49 2000
+++ Functions/Zle/predict-on Wed Feb 23 11:45:21 2000
@@ -64,7 +64,7 @@
# get out of that `case'.
repeat 1
do
- zstyle -s ":completion:${curcontext}" cursor crs
+ zstyle -s ":completion:${curcontext}:" cursor crs
case $crs in
(complete)
# At the place where the completion left it, if it is after
--
Sven Wischnowsky wischnow@informatik.hu-berlin.de
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: PATCH: Corrected style test in prediction
2000-02-23 10:46 Sven Wischnowsky
@ 2000-02-23 15:42 ` Bart Schaefer
0 siblings, 0 replies; 5+ messages in thread
From: Bart Schaefer @ 2000-02-23 15:42 UTC (permalink / raw)
To: Sven Wischnowsky, zsh-workers
On Feb 23, 11:46am, Sven Wischnowsky wrote:
} Subject: Re: PATCH: Corrected style test in prediction
}
} Bart Schaefer wrote:
}
} > Sven, please confirm ... I'm never sure about the number of trailing colons.
} >
} > Index: Functions/Zle/predict-on
} > ===================================================================
} > - elif zstyle -t ":completion:predict::::" list always
} > + elif zstyle -t ":completion:::predict::" list always
}
} The number of colons is still correct, but the original context name
} was correct, too. The `predict' was stored in the `function' field of
} the context name, indicating that completion was called from predict.
But in insert-and-predict we have:
local crs curcontext="${curcontext}"
[[ -z "$curcontext" ]] && curcontext=:::
curcontext="${curcontext#*:}predict:"
which makes the context be :completion:::predict::, with `predict' in
the `command' field. Surely the two should be the same? If not, why
not?
} However, the other call to zstyle had a missing colon, the one before
} the (not-given) tag.
Well, that part at least is less confusing now.
--
Bart Schaefer Brass Lantern Enterprises
http://www.well.com/user/barts http://www.brasslantern.com
^ permalink raw reply [flat|nested] 5+ messages in thread
* PATCH: Corrected style test in prediction
@ 2000-02-23 9:44 Bart Schaefer
0 siblings, 0 replies; 5+ messages in thread
From: Bart Schaefer @ 2000-02-23 9:44 UTC (permalink / raw)
To: zsh-workers
Sven, please confirm ... I'm never sure about the number of trailing colons.
Index: Functions/Zle/predict-on
===================================================================
@@ -122,7 +122,7 @@
then
compstate[list]=''
compstate[force_list]=yes
- elif zstyle -t ":completion:predict::::" list always
+ elif zstyle -t ":completion:::predict::" list always
then
compstate[force_list]=yes
fi
--
Bart Schaefer Brass Lantern Enterprises
http://www.well.com/user/barts http://www.brasslantern.com
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2000-02-23 15:54 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2000-02-23 15:53 PATCH: Corrected style test in prediction Sven Wischnowsky
-- strict thread matches above, loose matches on Subject: below --
2000-02-23 15:48 Sven Wischnowsky
2000-02-23 10:46 Sven Wischnowsky
2000-02-23 15:42 ` Bart Schaefer
2000-02-23 9:44 Bart Schaefer
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).