From d63be90a7ff4a6cf115e4da588e4838d28706960 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Bosdonnat?= Date: Mon, 10 Oct 2022 10:12:13 +0200 Subject: [PATCH] Recommend using --cwd=current in open-actions.conf Editors like Vim are basing path-related commands on the current working directory. Launching the action with the current CWD in hyperlink opens makes life easier and would work with every editor. --- docs/kittens/hyperlinked_grep.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/kittens/hyperlinked_grep.rst b/docs/kittens/hyperlinked_grep.rst index cf79e398e..b445a0f9d 100644 --- a/docs/kittens/hyperlinked_grep.rst +++ b/docs/kittens/hyperlinked_grep.rst @@ -17,12 +17,12 @@ following contents: # by the hyperlink_grep kitten and nothing else so far. protocol file fragment_matches [0-9]+ - action launch --type=overlay vim +${FRAGMENT} ${FILE_PATH} + action launch --type=overlay --cwd=current vim +${FRAGMENT} ${FILE_PATH} # Open text files without fragments in the editor protocol file mime text/* - action launch --type=overlay ${EDITOR} ${FILE_PATH} + action launch --type=overlay --cwd=current ${EDITOR} ${FILE_PATH} Now, run a search with::