Skip to content

Start new splits in same directory as current session

Warning: It bases on https://invent.kde.org/kde/konsole/merge_requests/43 which should be merged before this MR.

New splits start in the same directory as currently focused TerminalDisplay. If no TD is focused (e.g. when menu is active), directory of TD which was focused last is used. The same logic is applied to new window/tab, which used first TD in current tab, even if there were splits and another TD was focused.

Manual tests:

  • Enable "Start in same directory as current session" in Profile Settings
  • cd /; split. New split should start in /
  • cd /usr; split. New split should start in /usr
  • Select first split (the one with /); split. New split should start in /
  • Select split with / on first tab; create new tab/window. New tab/window should start in /
  • Select split with /usr on first tab; create new tab/window. New tab/window should start in /usr

Fixes: https://bugs.kde.org/show_bug.cgi?id=411332

Merge request reports