Merge branch 'hyperlinked-grep-only-matches' of https://github.com/groves/kitty

This commit is contained in:
Kovid Goyal
2022-08-30 06:59:53 +05:30
2 changed files with 42 additions and 9 deletions

View File

@@ -74,6 +74,14 @@ to :program:`rg`. How to do that varies based on the shell:
To learn more about kitty's powerful framework for customizing URL click
actions, see :doc:`here </open_actions>`.
By default, this adds hyperlinks for several parts of ripgrep output: the
per-file header, match context lines, and match lines. You can control which
items are linked with a :command:`--kitten hyperlink` flag. For example,
:command:`--kitten hyperlink=matching_lines` will only add hyperlinks to the
match lines. :command:`--kitten hyperlink=file_headers,context_lines` will
link file headers and context lines but not match lines.
:command:`--kitten hyperlink` may be specified multiple times.
Hopefully, someday this functionality will make it into some `upstream grep
<https://github.com/BurntSushi/ripgrep/issues/665>`__ program directly removing
the need for this kitten.