[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Groff] gtroff & soelim don't recognize ~ in paths
From: |
Keith Marshall |
Subject: |
Re: [Groff] gtroff & soelim don't recognize ~ in paths |
Date: |
Tue, 11 Apr 2006 05:07:51 +0100 |
On Tuesday 11 April 2006 4:08 am, Greg 'groggy' Lehey wrote:
> > And you might also consider this, in the bash *shell*:
> >
> > $ dir='~'
> > $ ls $dir
> > ls: ~: No such file or directory
>
> Arguably that's a bug in bash.
Nope. It's completely analogous to:
$ dir='$HOME'
$ echo $dir
$HOME
$ eval echo $dir
/home/keith
and this is perfectly correct Bourne shell behaviour, well understood,
and fully documented -- shell variables undergo only one round of
expansion at each `eval'; they are never recursively expanded.
Regards,
Keith.
- Re: [Groff] gtroff & soelim don't recognize ~ in paths, (continued)
- Re: [Groff] gtroff & soelim don't recognize ~ in paths, Werner LEMBERG, 2006/04/10
- Re: [Groff] gtroff & soelim don't recognize ~ in paths, Tadziu Hoffmann, 2006/04/11
- Re: [Groff] gtroff & soelim don't recognize ~ in paths, Larry Kollar, 2006/04/11
- Re: [Groff] gtroff & soelim don't recognize ~ in paths, Miklos Somogyi, 2006/04/11
- Re: [Groff] gtroff & soelim don't recognize ~ in paths, Tadziu Hoffmann, 2006/04/11
- Re: [Groff] gtroff & soelim don't recognize ~ in paths, Werner LEMBERG, 2006/04/11
- Re: [Groff] gtroff & soelim don't recognize ~ in paths, Larry Kollar, 2006/04/10
- Re: [Groff] gtroff & soelim don't recognize ~ in paths, Werner LEMBERG, 2006/04/10
- Re: [Groff] gtroff & soelim don't recognize ~ in paths, Keith Marshall, 2006/04/10
- Re: [Groff] gtroff & soelim don't recognize ~ in paths, Greg 'groggy' Lehey, 2006/04/10
- Re: [Groff] gtroff & soelim don't recognize ~ in paths,
Keith Marshall <=