#!/bin/sh rg --vimgrep "$@" | kak -c "${KAKOUNE_SESSION}" -e 'try %{db! *grep*}; rename-buffer *grep*; set-option window filetype grep; evaluate-commands -try-client %opt{toolsclient} %{ buffer *grep*; set-option window filetype grep }'