bug-bash
[Top][All Lists]
Advanced

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

Re: \w, $PWD and pwd builtin return "//" instead of '/'


From: mike b
Subject: Re: \w, $PWD and pwd builtin return "//" instead of '/'
Date: Sun, 13 Jan 2019 03:07:17 +0100

Ah, something was telling me that this could not have been missed, but
after checking behavior on couple of different shells (csh, ksh, tcsh) I
was convinced that it's not a proper behavior. Though now I see that, e.g.,
dash does the same thing. Note to myself: always check what POSIX has to
say. Or at least remember to run through the FAQ. :)

Anyways, thanks for your feedback!

niedz., 13 sty 2019 o 02:43 Chet Ramey <chet.ramey@case.edu> napisaƂ(a):

> On 1/12/19 7:52 PM, mike b wrote:
> > Upon changing directory, with "//" passed as an argument, the trailing
> '/'
> > is still displayed when cwd is looked up by Bash:
> >
> > bash-5.0# cd //
> > bash-5.0# pwd
> > //
> > bash-5.0# echo $PWD
> > //
>
> Bash FAQ, question E10. That should tell you how long this question has
> been asked. :-)
>
> --
> ``The lyf so short, the craft so long to lerne.'' - Chaucer
>                  ``Ars longa, vita brevis'' - Hippocrates
> Chet Ramey, UTech, CWRU    chet@case.edu    http://tiswww.cwru.edu/~chet/
>


reply via email to

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