Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > gnu.bash.bug > #16608

Re: Error expanding variable containing a directory name

Path csiph.com!xmission!news.snarked.org!news.linkpendium.com!news.linkpendium.com!panix!usenet.stanford.edu!not-for-mail
From Eli Schwartz <eschwartz@archlinux.org>
Newsgroups gnu.bash.bug
Subject Re: Error expanding variable containing a directory name
Date Thu, 23 Jul 2020 13:41:10 -0400
Lines 89
Approved bug-bash@gnu.org
Message-ID <mailman.418.1595526083.24492.bug-bash@gnu.org> (permalink)
References <738aff45-aa58-4cfc-2967-92ec87f2661b@posteo.de> <395a4cd2-7b79-3882-e8d0-1b525d2b7601@archlinux.org>
NNTP-Posting-Host lists.gnu.org
Mime-Version 1.0
Content-Type multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="7mZVCpjojFGjzmiQVGHtYRZ3SIGoVu24m"
X-Trace usenet.stanford.edu 1595526083 1756 209.51.188.17 (23 Jul 2020 17:41:23 GMT)
X-Complaints-To action@cs.stanford.edu
To bug-bash@gnu.org
Envelope-to bug-bash@gnu.org
X-Spam-BL-Results
DKIM-Signature v=1; a=rsa-sha256; c=relaxed/simple; d=archlinux.org; s=orion; t=1595526073; bh=ocQ8BBGedmzs4u9rl9tfYf1Znf2iiNrIA5rXdiWmHn8=; h=Subject:To:References:From:Date:In-Reply-To; b=n1/XyuBka9hlA4jZS7Xprd4jnW+ls1nfj/9CwMLKHLwlAtSCYC8pIcnfv6kPrfdfP HmpuoJZ3jQM6wP8t8L9ofg/P9cyrRKr8McwQtlpAV/sJ98yTAD6g3vTzl014iN2TRL a5nRmGdXeY374ZQpN5cllSy8x2eQlqtXcrpG/d3mYR2Ljf2olS5ukX2mNRsBb1m7v+ 5cdLfMXKbng5vVqMQAvceoZR6nQMxbOOIAKcdTa2OulgqPsD33/rk7XFCV1JcyFeYd Ucv5enOAbf6SHvlsi1i7J/EhPLFiQCRkFTd8Hs8EftA/q38Z+C1b8WyQfpF7bzI1gW kgjjzKL9fnkDk23wG7wmK0LcsTwfGOvC8EbkcjIPxmvZbs3oCBlHrrjV2CXdBilOJ9 Ud1ltPMrSJ4m7DygoMkaGqFllU3GgA7xJQVG4ZqaI08bTXXJSA6W8huYiQI/ZHV1WR z9qKaHF4KItnf+XqwNlhZHx1oaaHvsfer5pLjhrKCfWl2Fd0tpPPLTwQp/aVRXCnC3 8QoQ8bsz3Ju6R0tMd6TwiV4/eEBQyvmGvNanpSVetbOywrvEj46TAkEEagMYlnth+c 2nRaZR8tQaVjyTom8kURlYUXzouZGfQW6a2W5VwtOxLixnM9fs6fMovykuUhfp1iom c7cahhH+vA/rCrC1vb+2cXmA=
X-Clacks-Overhead GNU Terry Pratchett
User-Agent Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0
In-Reply-To <738aff45-aa58-4cfc-2967-92ec87f2661b@posteo.de>
Received-SPF pass client-ip=2a01:4f8:160:6087::1; envelope-from=eschwartz@archlinux.org; helo=orion.archlinux.org
X-detected-operating-system by eggs.gnu.org: No matching host in p0f cache. That's all we know.
X-Spam_score_int -53
X-Spam_score -5.4
X-Spam_bar -----
X-Spam_report (-5.4 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-1, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001 autolearn=ham autolearn_force=no
X-Spam_action no action
X-BeenThere bug-bash@gnu.org
X-Mailman-Version 2.1.23
Precedence list
List-Id Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe <https://lists.gnu.org/mailman/options/bug-bash>, <mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive <https://lists.gnu.org/archive/html/bug-bash>
List-Post <mailto:bug-bash@gnu.org>
List-Help <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe <https://lists.gnu.org/mailman/listinfo/bug-bash>, <mailto:bug-bash-request@gnu.org?subject=subscribe>
X-Mailman-Original-Message-ID <395a4cd2-7b79-3882-e8d0-1b525d2b7601@archlinux.org>
X-Mailman-Original-References <738aff45-aa58-4cfc-2967-92ec87f2661b@posteo.de>
Xref csiph.com gnu.bash.bug:16608

Show key headers only | View raw


[Multipart message — attachments visible in raw view] - view raw

On 7/23/20 12:08 PM, Lutz Adam wrote:
> Description:
>        The content of $ML is "/media/lad".  There's a directory
> /media/lad/p24. Typing the command
>             ls $ML/p24<TAB-key>
>        a backslash is put befor "$" and the line looks like:
>             ls \$ML/p24/
>        Typing the ENTER key shows:
>             ls: cannot access '$ML/p24/': No such file or directory.
> 
> Repeat-By:
>         Create a variable containing a directory name. Put a
> subdirectory there under.
>         Type a "$" and the variable followed by a slash, the name of the
> subdirectora and the TAB-key.
> 
> 
> The OS is Linux Mint 20

The built-in bash tab completion actually does this okay. Are you using
the bash-completion project addon functionality?

[eschwartz@arch ~]$ ls $HOME/<TAB>
 --> rewrites in-place to...
[eschwartz@arch ~]$ ls \$HOME/
[eschwartz@arch ~]$ bash --norc --noprofile
bash-5.0$ ls $HOME/<TAB>
Display all 163 possibilities? (y or n)
[...]


-- 
Eli Schwartz
Arch Linux Bug Wrangler and Trusted User

Back to gnu.bash.bug | Previous | Next | Find similar


Thread

Re: Error expanding variable containing a directory name Eli Schwartz <eschwartz@archlinux.org> - 2020-07-23 13:41 -0400

csiph-web