zsh-users
 help / color / mirror / code / Atom feed
* variable containing the current command
@ 1999-05-26 20:23 benjamin
  1999-05-26 21:40 ` Sweth Chandramouli
  0 siblings, 1 reply; 6+ messages in thread
From: benjamin @ 1999-05-26 20:23 UTC (permalink / raw)
  To: zsh-users

Is there a zsh environment variable that contains the current command
so that it can be referenced in preexec() or precmd() (or ideally both)?

e.g.

precmd() { echo "Just did:$CURRENT_CMD" }
preexec() { echo "Ready to do:$CURRENT_CMD" }

localhost[1]% ls
Ready to do:ls
foo		bar		snafu		tarfu
Just did:ls
localhost[2]%

Ben
-- 
Benjamin Korvemaker
benjamin@cs.ualberta.ca
	I have yet to meet a C compiler that is more friendly
	   and easier to use than eating soup with a knife.


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~1999-05-31  5:46 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1999-05-26 20:23 variable containing the current command benjamin
1999-05-26 21:40 ` Sweth Chandramouli
1999-05-26 22:17   ` Bart Schaefer
1999-05-26 22:50     ` Michael Barnes
1999-05-31  5:46       ` Bart Schaefer
1999-05-28 23:13     ` benjamin

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