On Tue, Dec 06, 2011 at 06:05:30PM +0100, Matthias Lederhofer wrote:
> Nicholas Marriott wrote:
> > If you start PWD with it already in the environment, it is marked as
> > exported - this is the same as any other variable:
>
> Ah, ok. Anyway it shows that ksh uses $PWD as any other shell, even
Nicholas Marriott wrote:
> If you start PWD with it already in the environment, it is marked as
> exported - this is the same as any other variable:
Ah, ok. Anyway it shows that ksh uses $PWD as any other shell, even
though it doesn't export it by default.
> For your use, you want to be able to
On Tue, Dec 06, 2011 at 07:43:18AM +0100, Matthias Lederhofer wrote:
> Nicholas Marriott wrote:
> > Well, not necessarily, ksh for example does not export PWD.
>
> I could not verify this (on openbsd):
>
> matled@openbsd:~% ksh
If you start PWD with it already in the environment, it is mark
Nicholas Marriott wrote:
> Well, not necessarily, ksh for example does not export PWD.
I could not verify this (on openbsd):
matled@openbsd:~% ksh
$ cd /tmp/b
$ env |grep ^PWD
/tmp/b
$ sh -c pwd
/tmp/b
$ env -i sh -c pwd
/tmp/a
> > What do you mean by the last tw
On Mon, Dec 05, 2011 at 06:28:59PM +0100, Matthias Lederhofer wrote:
> Nicholas Marriott wrote:
> > I'm not really convinced by all the PWD talk, the canonical way to find
> > the current working directory is to call getcwd(). Not to use PWD, that
> > is just a shell convenience. I don't think app
Nicholas Marriott wrote:
> I'm not really convinced by all the PWD talk, the canonical way to find
> the current working directory is to call getcwd(). Not to use PWD, that
> is just a shell convenience. I don't think applications should ever need
> to check PWD rather than calling getcwd(). They
On Sat, Dec 03, 2011 at 06:05:44PM +0100, Matthias Lederhofer wrote:
> Nicholas Marriott wrote:
> > Hmm. As far as I can see xterm doesn't set PWD, how come xterm doesn't
> > have this problem?
> >
> > If you make sure your shell exports PWD and add it to
> > update-environment, tmux will set it
Nicholas Marriott wrote:
> Hmm. As far as I can see xterm doesn't set PWD, how come xterm doesn't
> have this problem?
>
> If you make sure your shell exports PWD and add it to
> update-environment, tmux will set it in the environment. Does that not
> that work? It might be easier to just add PWD
Hmm. As far as I can see xterm doesn't set PWD, how come xterm doesn't
have this problem?
If you make sure your shell exports PWD and add it to
update-environment, tmux will set it in the environment. Does that not
that work? It might be easier to just add PWD to update-environment by
default.
O