This question is very similar to ConEmu with Git Bash - Show folder in tab bar, except that it relates to Bash running in the Windows Subsystem for Linux.
I'd like to display the current directory in the tab bar. The ConEmu documentation for setting working dir in bash says to use the command PROMPT_COMMAND='ConEmuC -StoreCWD' in my profile, but I am unable to run that command. If I do, I get the following error:
conan@ALLP0122 /mnt/c/Program Files/ConEmu/ConEmu $ ./ConEmuC.exe
Failed to connect to bash.exe: No such file or directory
Am I using the correct approach but have done something wrong, or should I be trying something else? I'm sure it's possible to do this, but how do I achieve it in ConEmu?
ConEmu 190714
Update: I'm still trying to do this, so I've started again. I've tried following the provided instructions, by setting my task command as suggested to:
set "PATH=%ConEmuBaseDirShort%\wsl;%PATH%" & %ConEmuBaseDirShort%\conemu-cyg-64.exe --wsl -cur_console:pm:/mnt
I believe that the conemu-cyg-64.exe means I'm running the cygwin/msys connector,but I'm not sure how to know whether I'm running wslbridge?
I've set my task parameters to:
/dir %CD% /icon "%USERPROFILE%\AppData\Local\lxss\bash.ico"
I have a bunch of stuff in my PS1 that displays Git info correctly, and I've made sure that unprintable characters are escaped as mentioned here, and I've added the following to the end of my .bashrc:
if [[ -n "${ConEmuPID}" ]]; then
PS1="$PS1\[\e]9;9;\"\w\"\007\e]9;12\007\]"
fi
I've also tried adding this without the if just in case, but it made no difference. I still don't see the path in the tab or title bar:

What have I missed?
Of course you are not able to run ConEmuC in WSL. ConEmuC.exe is native Windows binary and certainly it can't be started in linux subsystem.
In spite of weird and mystic communication between WSL processes and Windows conhost, ConEmu has absolutely no ability to "hack" them with ConEmuHk automatically.
You shall do
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With