What is the command to set startup directory in Git Bash?
When I start Git Bash, the startup directory is Bitbust directory in C drive, so I must change the working directory with cd
command.
But I think it is an unnecessary process. I want the startup directory to be my working directory where Git Bash is started.
Right click on the shortcut, and select properties. Navigate to the "shortcut" tab.
There are two things you need to change here. First, by default, the Target field will end in --cd-to-home
- remove it. Once you've done that, you can edit the Start in
field and give it any directory you want.
E.g., this is how the shortcut looks on my machine:
After editing, you'll have:
You could also, of course, create multiple Git Bash shortcuts to start in each directory you're interested in.