This is the mail archive of the cygwin@cygwin.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: Bash puzzle: Spaces, environment variables and tab completion


> Although I appreciate Gary's encouragement, going
> around bash instead of struggling with it, does
> seem the better solution.

Well now, I never said you couldn't cheat a *little* ;-).

>  There were several
> variations on the same theme on this bypass
> solution.  Thanks to Ehud, Michael and Igor.
> Basically either symbolically link or mount a (non
> spaced) file to the problem path.  Then I can
> define an environment variable to that link/mount.
>

Don't forget about cygpath's ability to transfigure spaced pathnames into
spaceless ones:

PF=$(cygpath -u $(cygpath -d '/cygdrive/c/Program Files'))

This will tab-complete $PF/whatever, "cd $PF", "ls $PF/G<tab complete>" just
fine, etc etc.  The only downside is that you end up looking at those ugly (but
spaceless) short, squiggleized names.

How's that for pounding, Randall? ;-)

--
Gary R. Van Sickle
Brewer.  Patriot.


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]