On linux you can get this from /proc/PID_OF_SHELL/cwd. Alternatively you could do something like vte and put something in /etc/profile.d to snoop the directory in PROMPT_COMMAND: https://github.com/GNOME/vte/blob/master/src/vte.sh (or lie and claim to be vte to that script and use the same protocol...)
Already implemented, search kitty.conf for with_cwd
This doesn't exist: Ignoring unknown config key: with_cwd Is it a bug or has the key changed name?
new_tab_with_cwd
new_os_window_with_cwd
new_window_with_cwd
Most helpful comment
new_tab_with_cwdnew_os_window_with_cwdnew_window_with_cwd