Speedup syntax highlighting of redirection targets

Instead of checking twice whether the redirection target is a valid file,
use the return value from test_redirection_target().

Closes #12276
This commit is contained in:
Lennard Hofmann
2026-01-05 13:29:58 +01:00
committed by Johannes Altmanninger
parent 5930574d8a
commit c638401469
3 changed files with 127 additions and 63 deletions

View File

@@ -133,7 +133,7 @@ Variable Meaning
.. envvar:: fish_color_end process separators like ``;`` and ``&``
.. envvar:: fish_color_error syntax errors
.. envvar:: fish_color_param ordinary command parameters
.. envvar:: fish_color_valid_path parameters that are filenames (if the file exists)
.. envvar:: fish_color_valid_path parameters and redirection targets that are filenames (if the file exists)
.. envvar:: fish_color_option options starting with "-", up to the first "--" parameter
.. envvar:: fish_color_comment comments like '# important'
.. envvar:: fish_color_selection selected text in vi visual mode