Skip to content

Fish autocomplete doesn't work with inv command #1036

@Techcable

Description

@Techcable

Two things need to be done to fix this.

In order for fish to recognize inv as a supported command, pass ---comand inv to complete in addition to --comand invoke.

complete --command {binary} --no-files --arguments '(__complete_{binary})'

Additionally, for completion autoloading to work, the inv.fish file needs to be system linked to invoke.fish.

I would contribute a fix, but it looks like you use {binary} instead of hard-coding invoke. The built-in template logic has no way to expand ["inv", "invoke"] to "--command invoke --comand inv". The second issue with a fix is that I don't know to install inv.fish alongside invoke.fish.

Are you okay with hardcoding --command inv in the completion file, and how would I modify the logic for installing completions?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions