Bug 244449 - detect symbolic links in pwd when creating new tab
Summary: detect symbolic links in pwd when creating new tab
Status: RESOLVED FIXED
Alias: None
Product: konsole
Classification: Applications
Component: general (show other bugs)
Version: 2.5
Platform: Ubuntu Linux
: NOR wishlist
Target Milestone: ---
Assignee: Konsole Developer
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-07-13 02:08 UTC by Constantin Berzan
Modified: 2021-05-16 16:58 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Constantin Berzan 2010-07-13 02:08:54 UTC
Version:           2.5 (using KDE 4.4.4) 
OS:                Linux

I often have a deeply nested directory (~/abc/2010/summer/project123) symlinked to something shorter (~/now). If I cd ~/now in Konsole and then create a new tab, the new tab starts in the expanded (real) directory ~/abc/2010/summer/project123.  It would be really great if Konsole could detect the symbolic link, and create the new tab in the same directory (~/now).

Reproducible: Always

Steps to Reproduce:
cd /tmp
mkdir -p deeply/nested/dir
ln -s deeply/nested/dir short
cd short
<Ctrl+Shift+N>

Actual Results:  
new tab is created in /tmp/deeply/nested/dir

Expected Results:  
new tab would ideally be created in /tmp/short
Comment 1 Jekyll Wu 2011-07-24 06:28:17 UTC
That sounds nice, but I doubt whether it is possible to implement that.

konsole gets the PWD of the terminal process(shell,vim,etc) by looking at(on Linux) /proc/<pid>/cwd, which is itself a symlink pointing to the expanded PWD in absolute path. when you have a symlink, you can easily know its target. But when you only have the target, how can you find which symlink has taken you here?
Comment 2 Kurt Hindenburg 2011-07-24 12:58:07 UTC
I agree w/ #1, there is another bug report about symlinks that I looked into it.  I don't think this possible.
Comment 3 Erin Yuki Schlarb 2021-05-16 14:26:47 UTC
Would it be possible to fix this one now since Konsole does display the unresolved working directory path in its title/tab bar nowadays?
Comment 4 Erin Yuki Schlarb 2021-05-16 16:58:27 UTC
NVM, the comment at https://bugs.kde.org/show_bug.cgi?id=327720#c1 explains what is needed to make this work.

Turns out oh-my-zsh has support for this limited to macOS' iTerm.app at the moment. I'll open a PR with them instead.