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

Re: file completion(?) erases word typed



On Aug 24,  7:13pm, Daniel Shahaf wrote:
}
} >           +_path_files:713> compadd -Qf -J -default- -p usr/local/bin/ -s '' -W /usr/local/bin/ -M 'r:|/=* r:|=*' -a tmp1
} > 
} > I have no idea why ignoring the path minus its leading slash would ever
} > be correct, but in any case this appears to be adding the full path by
} > two different and contradictory approaches.
} 
} What _absolute_command_paths intended to be is:
} 
} - You can type in an absolute path to an executable file, even if that
}   file is not in $PATH or in $commands.

What's the reason for passing -P / to _path_files in _typed-in_* ?

That's what's causing the strange -p usr/local/bin getting passed to
compadd.  Despite what the doc says, _path_files doesn't actually pass
the -P option along to compadd, instead it calls "compset -P" which
makes it an ignored prefix instead.

I'm still not sure whether (or what) this has to do with the word on
the line disappearing.



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