From 994ee848f6b7d9cda314a4bf8b83680f99c7c661 Mon Sep 17 00:00:00 2001 From: Daniel Lundin Date: Thu, 8 Feb 2024 10:23:55 +0100 Subject: [PATCH] nvim: osc7 goodness --- .config/nvim/lua/config/options.lua | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/.config/nvim/lua/config/options.lua b/.config/nvim/lua/config/options.lua index 608968e..3e0ab0f 100644 --- a/.config/nvim/lua/config/options.lua +++ b/.config/nvim/lua/config/options.lua @@ -21,3 +21,10 @@ vim.filetype.add({ templ = "templ", }, }) + +-- AutoCommand OSC7 workaround for tmux +-- see https://github.com/neovim/neovim/issues/21771 +vim.api.nvim_create_autocmd("dirchanged", { + pattern = "*", + command = 'call chansend(v:stderr, printf("\\033]7;%s\\033", v:event.cwd))', +})