This post shows the way to launch VS Code from your git bash.
At first, create a
.bash_profile file at your home directory and add the following alias in your
cd ~/ on git bash then you can move your home directory.
if you could make the no-name file, like .bash_profile, on the file explorer, the file explorer warned you and didn’t allow to create no-name file. So it’s a easy way to create the no-name file on git bash.
Then edit the
.bash_profile file on your editor.
If you want a one-line command, see the the following one.
By the way, the post on the reference url says not a
.bash_profile but a
However, in my PCs, git bash didn’t read the
.bashrc and another PC’s git bash warned “there is no .bash_profile.”. I guess
.bash_profile is better.
There is an another way to add the alias into
Though the path depends on your PC environment. So I prefer