i3: Fix opening kitty in the current working dir

Since I run kitty with --single-instance, xcwd does not work for it.
Replace it with a short script that retrieves the CWD for the focused
window through the remote-control ls command.

This changes the current behaviour slightly, since now only terminals
are used and not any X window (which I rarely used or needed) and that
the working dir of the shell running in kitty will be used and not of
any deeper children. I'm still unsure if I want the latter back, but
will figure this out in the future.

This is an addendum to 0139294831 ("Use kitty instead of st as
terminal").
This commit is contained in:
2025-05-27 18:07:13 +02:00
parent 0c17ae8280
commit a34a00eae6
3 changed files with 33 additions and 3 deletions

1
.local/bin/kitty-cwd Symbolic link
View File

@@ -0,0 +1 @@
/home/user/projs/dotfiles/.config/kitty/get_cwd.sh