Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Adding nocorrect to a preexec function
- X-seq: zsh-users 9836
- From: Eric Smith <es@xxxxxxxxxxxx>
- To: zsh-users@xxxxxxxxxx
- Subject: Adding nocorrect to a preexec function
- Date: Wed, 18 Jan 2006 00:11:30 +0100
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
I use the following function (which is probably more complex that
required) and wish to add nocorrect to it. How would I do that
as in all the obvious (to me) places it does not seem to work.
function preexec {
local cmd
local application
cmd=(${(Q)${(z)3}})
eval "function ${(q)cmd[1]} {
unsetopt noglob
cost ${(q)cmd[1]}" '$*
unfunction' "${(q)cmd[1]}
}"
setopt noglob
}
Thanks
--
Eric Smith
Messages sorted by:
Reverse Date,
Date,
Thread,
Author