From bb33c66570fece65edac2d1a29794c9720318797 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Wed, 26 Apr 2023 16:38:25 +0530 Subject: [PATCH] Fix #6213 --- kittens/hints/main.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/kittens/hints/main.py b/kittens/hints/main.py index d4c9760e6..a2a18eb3f 100644 --- a/kittens/hints/main.py +++ b/kittens/hints/main.py @@ -90,7 +90,8 @@ for the operating system. Various special values are supported: copy the match to the specified buffer, e.g. :code:`@a` :code:`default` - run the default open program. + run the default open program. Note that when using the hyperlink :code:`--type` + the default is to use the kitty :doc:`/open_actions` facilities. :code:`launch` run :doc:`/launch` to open the program in a new kitty tab, window, overlay, etc. @@ -349,8 +350,9 @@ def handle_result(args: List[str], data: Dict[str, Any], target_window_id: int, else: from kitty.conf.utils import to_cmdline cwd = data['cwd'] - program = get_options().open_url_with if program == 'default' else program - if text_type == 'hyperlink': + is_default_program = program == 'default' + program = get_options().open_url_with if is_default_program else program + if text_type == 'hyperlink' and is_default_program: w = boss.window_id_map.get(target_window_id) for m in matches: if w is not None: