Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: PATCH: Run builtins, functions, etc. under zpty
- X-seq: zsh-workers 13124
- From: "Bart Schaefer" <schaefer@xxxxxxxxxxxxxxxxxxxxxxx>
- To: zsh-workers@xxxxxxxxxxxxxx
- Subject: Re: PATCH: Run builtins, functions, etc. under zpty
- Date: Mon, 6 Nov 2000 06:59:59 +0000
- In-reply-to: <1001105223736.ZM1787@xxxxxxxxxxxxxxxxxxxxxxx>
- Mailing-list: contact zsh-workers-help@xxxxxxxxxxxxxx; run by ezmlm
- References: <1001105223736.ZM1787@xxxxxxxxxxxxxxxxxxxxxxx>
On Nov 5, 10:37pm, Bart Schaefer wrote:
}
} This patch copies code from the clone module into newptycmd(), so that the
} forked process set up on the pty is initially a clone of the current shell.
} Then instead of calling execve(), the command can be parsed and executed
} with execode().
I forgot that this requires a change to nslookup.
Also, I committed a tweak to newptycmd() after sending the patch in 13123,
to unset `interactive' in the cloned shell before calling execode(). This
seems like the right thing to do; the clone itself isn't interactive any
more, even if the command it's eval'ing probably is, and it prevents the
saving of history or sourcing of .zlogout should an `exec' or `exit' be
performed in the clone. (Patch for that not included here, it's in CVS.)
Index: Functions/Misc/nslookup
===================================================================
@@ -24,7 +24,7 @@
[[ -z "$pager" ]] && pager="${opager:-more}"
(( $#pmpt )) || pmpt=(-p '> ')
-zpty nslookup nslookup "$@"
+zpty nslookup command nslookup "${(q)@}"
zpty -r nslookup line '*
> '
--
Bart Schaefer Brass Lantern Enterprises
http://www.well.com/user/barts http://www.brasslantern.com
Zsh: http://www.zsh.org | PHPerl Project: http://phperl.sourceforge.net
Messages sorted by:
Reverse Date,
Date,
Thread,
Author