Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 10 Jun 2013 07:27:27 -0700
From:      Jeremy Chadwick <jdc@koitsu.org>
To:        "David P. Caldwell" <david@code.davidpcaldwell.com>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: With fresh 9.1 install, bash completion no longer expands "$HOME"
Message-ID:  <20130610142727.GA66204@icarus.home.lan>

next in thread | raw e-mail | index | archive | help
Re: http://lists.freebsd.org/pipermail/freebsd-questions/2013-June/251607.html

This has nothing to do with FreeBSD 9.0 vs. 9.1 other than the fact that
the package on 9.0 is older than 9.1.  Instead, this has everything to
do with the difference between bash versions you're using.  Remember:
packages and ports 99% of the time are third-party software (in this
case GNU), and therefore any changes in behaviour between versions are
entirely independent of FreeBSD.

The feature you like from bash 4.1 was removed in some manner of
speaking in bash 4.2.  This prompted a user to complain -- please read
the thread (not just the post) in full, because you will see there are
others who *do not* like this behaviour:

http://lists.gnu.org/archive/html/bug-bash/2011-02/msg00274.html

In bash 4.2.29 -- which is technically "patch 029 for bash 4.2" -- the
feature you desire got moved into a shopt feature called "direxpand",
with the default being disabled.  Because bash 4.3 is not out yet, you
will not find any mention of this in the official bash CHANGES file at
this time.  Instead, you will find the answer in the official bash42-029
patch itself (read the top):

ftp://ftp.gnu.org/gnu/bash/bash-4.2-patches/bash42-029

If you do not like this default, or feel strongly about this whole thing
and want to discuss it, the GNU bug-bash mailing list is the place:

http://www.gnu.org/software/bash/

To enable direxpand, use "shopt -s direxpand".  You can put this command
in your ~/.bashrc.

-- 
| Jeremy Chadwick                                   jdc@koitsu.org |
| UNIX Systems Administrator                http://jdc.koitsu.org/ |
| Making life hard for others since 1977.             PGP 4BD6C0CB |




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20130610142727.GA66204>