Search code examples
bashwindows-10cdwindows-subsystem-for-linux

Windows 10 Bash - how to automatically cd into a directory after launching


Is there a way for Bash to automatically change the directory after it is launched?

At present I have to type cd /mnt/c... each time I open Bash.


Solution

  • Add your cd /mnt/c command (on a new line) at the end of your ~/.bashrc file.