zsh-workers
 help / color / mirror / code / Atom feed
* Re: How could one prepend a string to every command?
       [not found] ` <c21da7250801090144s3be41a09l91fc6f35c469ecbb@mail.gmail.com>
@ 2008-01-09 11:07   ` Jörg Sommer
  0 siblings, 0 replies; only message in thread
From: Jörg Sommer @ 2008-01-09 11:07 UTC (permalink / raw)
  To: zsh-workers

Hi Ian,

"Ian Tegebo" <ian.tegebo@gmail.com> wrote:
> Is there any way zsh could prepend a string, e.g. '/usr/bin/env', to
> each command?  I saw 'precmd' but I don't think that's what I want.

Maybe you can replace the accept-line widget.

accept-line()
{
    BUFFER="/usr/bin/env $BUFFER"
    zle .accept-line
}
zle -N accept-line

Bye, Jörg.
-- 
“Unfortunately, the current generation of mail programs do not have
 checkers to see if the sender knows what he is talking about”
            (Andrew S. Tanenbaum)


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2008-01-09 11:09 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <c21da7250801090143q7d14698cn4c3c72271c208543@mail.gmail.com>
     [not found] ` <c21da7250801090144s3be41a09l91fc6f35c469ecbb@mail.gmail.com>
2008-01-09 11:07   ` How could one prepend a string to every command? Jörg Sommer

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).