nmh-workers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Nmh-workers] whatnow(1)'s cd Doesn't Affect it's mime.


From: Ralph Corderoy
Subject: Re: [Nmh-workers] whatnow(1)'s cd Doesn't Affect it's mime.
Date: Wed, 18 Jan 2017 19:27:21 +0000

Hi Jon,

> I do think that your example above is sort of bogus; whatnow does not
> provide full shell functionality so you can't do things like that
> anyway.

It's not bogus as it happened to me in normal use, that's how I found
the problem.  whatnow isn't a full shell, but that doesn't matter.
Neither are text editors, debuggers, FTP clients, `gawk -l filefuncs',
etc.  All of these can offer `cd' and not have whatnow's bug.

> If I do "more foo" and "!cd bar" and then quit "more" I'm not in "bar"

Correct.  And more(1) was never in bar.  This starts a subshell and that
changes directory and then exits.  more(1) doesn't have a built-in `cd'
so it's not relevant here.

I don't think you've understood the problem I'm complaining about.  :-)
It has nothing to do with whatnow not affecting the parent shell, during
or after exit.

whatnow offers two commands, `ls' and `mime'.  Both are available at the
same prompt.  `cd' affects `ls' and not `mime'.  Normal Unix programs
that offer a built-in `cd' don't have it affect only some of the
subsequent commands.  That's because they implement `cd' with chdir(2).
whatnow doesn't, and this pretence is imperfect so bites the user.

-- 
Cheers, Ralph.
https://plus.google.com/+RalphCorderoy



reply via email to

[Prev in Thread] Current Thread [Next in Thread]