Search code examples
fish

Fish autocomplete pager doesn't highlight options when tabbing through them


Previously, fish would highlight the currently selected autocomplete. Now it doesn't. Do you know how to make it highlight it?

Observed behavior an example of me typing cd, then pressing tab, and all the options appear, but the currently autocompleted one isn't highlighted

Expected behavior

An example of someone using fish shell to highlight autocomplete answers successfully


Solution

  • The selected background color is stored in $fish_pager_color_selected_background, or $fish_color_search_match if that isn't set.

    It seems either these aren't set, or the value you chose looks like your terminal's background. Given that you now have a light background and fish has no way to detect it that's hard to avoid.

    Use something like

    set -g fish_pager_color_selected_background --background=533
    

    to set it. The value should look like arguments to fish's set_color builtin.

    See https://fishshell.com/docs/current/interactive.html#pager-color-variables for more information.