[Top][All Lists]

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

Re: Wrong prompt and incorrect parsing if completion is used

From: Chet Ramey
Subject: Re: Wrong prompt and incorrect parsing if completion is used
Date: Sun, 15 Aug 2010 12:21:20 -0400
User-agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv: Gecko/20100711 Lightning/1.0b1 Thunderbird/3.0.6

On 8/9/10 12:02 PM, Egmont Koblinger wrote:

> Start over, type the following (replace TAB by pressing the TAB key):
> ps1$ cd /biTAB`
> The auto-completed command looks exactly as the manually typed one, hence
> the expected behavior is the same.  However, press Enter, and the primary
> prompt gets displayed. Logically, however, this is still a secondary prompt
> (if you type another command, or press ^D, the behavior suggests this).
> Start over, type the following:
> ps1$ cd /biTAB`
> ps1$ cd /sbTAB`
> The following error is printed:
> bash: bad substitution: no closing `}' in "${to`
> cd /sbin/`
> Note that bash_completion doesn't have a shell variable named "to", it only
> has "toks", so seems like parsing the file pretty much goes off the track.
>  The error message cuts this word in half at a position depending on the
> length of the directory pathnames.

You're correct that this was a bug in bash.  Both of these are the result
of the same bug, which will be fixed in bash-4.2.


``The lyf so short, the craft so long to lerne.'' - Chaucer
                 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, ITS, CWRU    address@hidden    http://cnswww.cns.cwru.edu/~chet/

reply via email to

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