Re: bash tab variable expansion question?
On 27 Feb 2011 18:18:24 -0500, Chet Ramey wrote: >> On Sat, Feb 26, 2011 at 10:49 PM, gnu.bash.bug wrote: >> A workaround is fine but is the 4.2 behavior bug or not? > >It's a more-or-less unintended consequence of the requested change Eric >Blake referred to earlier in the thread. http://lists.gnu.org/archive/html/bug-bash/2011-02/msg00275.html (...) > The question is how to tell readline that the `$' should be quoted > under some circumstances but not others. There's no hard-and-fast > rule that works all the time, though I suppose a call to stat(2) > before quoting would solve part of the problem. I will have to give > it more thought. > > Chet Any updates on this issue? The workarounds for $PWD and $OLDPWD is not enough, and the "workaround" of going back on the command line and removing escape characters is not acceptable in my humble opinion. I often use environment variable-based tab completion to navigate to the correct directory on my system, but with bash 4.2 this is no longer an option. For example, with CODE=/path/to/dir and /path/to/dir/ containing test1/ and test2/, cd $CODE/test should give a list of $CODE/test1 $CODE/test2 when those directories exist, not "cd \$CODE/test". If there is no fix in sight for this issue, can someone point me to a guide for downgrading bash in recent popular Linux distros? thanks, -- John
Re: bash tab variable expansion question?
On 06/11/2012 10:10 AM, Pierre Gaston wrote: On Mon, Jun 11, 2012 at 10:59 AM, John Embretsen wrote: On 27 Feb 2011 18:18:24 -0500, Chet Ramey wrote: On Sat, Feb 26, 2011 at 10:49 PM, gnu.bash.bugwrote: A workaround is fine but is the 4.2 behavior bug or not? It's a more-or-less unintended consequence of the requested change Eric Blake referred to earlier in the thread. http://lists.gnu.org/archive/html/bug-bash/2011-02/msg00275.html (...) The question is how to tell readline that the `$' should be quoted under some circumstances but not others. There's no hard-and-fast rule that works all the time, though I suppose a call to stat(2) before quoting would solve part of the problem. I will have to give it more thought. Chet Any updates on this issue? (...) There have been many updates on this. There have been a "fix" available for some time now on this list . It is now available as an official patch ftp://ftp.gnu.org/gnu/bash/bash-4.2-patches/bash42-029 Thank you. For someone like me who is not active in this project it seems it is not very easy to keep track of bugs, patches and releases. Is there an issue number/bug number of some sort for this particular issue that I could use for this purpose? I hope the patch works well enough and that it will end up in Linux distros shortly. -- John