On 8/19/20 4:01 PM, Josh Triplett wrote:
> On Wed, Aug 19, 2020 at 03:33:49PM -0400, Chet Ramey wrote:
>> On 8/19/20 3:15 PM, Josh Triplett wrote:
>>> Bash Version: 5.0
>>> Patch Level: 18
>>> Release Status: release
>>> If FIGNORE contains the complete filename of a file, tab
>>> completion will not ignore it.
>> FIGNORE is a list of suffixes, and requires at least one character before
>> the suffix when matching.
> I'm wondering if either that might be changeable or there could be a way
> to specify full filenames to get the same treatment.
FIGNORE has behaved this way for 30 years, so there's not much chance that
behavior will change.
> I'd like to ignore
> specific filenames, rather than all filenames ending in a suffix. Or
> perhaps there could be an option that does a regex match (allowing
> things like ^ and $)?
You can do this with programmable completion, but you have to go through
the effort of defining the compspecs for the commands of interest. Or
you can use it in the default programmable completion (complete -D).