Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Broken completion on $prefix/*



I can't get file-completion in this context:

## define the variable '$prefix'
$ prefix=long/relative/path/to/stuff

## [slightly-OT]
## example of why that variable name made sense
## $ run-some-command --blah-dir $prefix/blah --arga-dir $prefix/arga

## example of where I wanted completion, but it didn't work
$ find $prefix/<Tab>
(shows completion for '/')

## Attempts with variable names $outputdir or $asdfdsa both work fine.
$ outputdir=$prefix
$ find $outputdir/<Tab>
(shows completion for 'long/relative/path/to/stuff')

$ asdfdsa=$prefix
$ find $asdfdsa/<Tab>
(shows completion for 'long/relative/path/to/stuff')

I assume this is an artifact of something localizing '$prefix' before 
its value is used for completion, but I don't see it right off.

Found using zsh 4.3.10 (patch level 1.4705) at work, but I'm pretty sure 
it's still present in latest git (assuming I'm setting up my fpath 
correctly on my home machine) and it's also in 4.3.4 (on an old server).

-- 
Best,
Ben



Messages sorted by: Reverse Date, Date, Thread, Author