how to change the location of the start directory in git bash

3,239 views
Skip to first unread message

Karthick Babu Sai Sankar Gupta

unread,
Sep 18, 2016, 3:00:00 PM9/18/16
to git-for-windows
Dear All,

I am very new to this git and git hub thing.

My operating system : Windows-7

used default installation

Version of Git installed : git version 2.10.0.windows.1

saisankarguptakb@W0020045 MINGW64 ~
$ pwd
/p/

When i checked the properties of git-bash

it displays like this





So instead of "P" directory, I would like to use "C:\gitprojects\git\".

Can somebody help me to get going on this ?

Thanks in advance,

regards
Karthick
Auto Generated Inline Image 1

Philip Oakley

unread,
Sep 18, 2016, 3:27:54 PM9/18/16
to Karthick Babu Sai Sankar Gupta, git-for-windows
The key part is to change your environment variables of HOMEDRIVE and HOMEPATH. (e.g. see http://stackoverflow.com/questions/2114111/where-does-git-config-global-get-written-to/5732395#5732395 for my answer regarding the --global location, and the comments to it)
 
I presume you are in a corporate work environment with 'the management / IT department' auto setting those values to some remote server which has been mapped to "P:".
 
The question is then, what are you allowed to change, and how?
 
If you can just update that link, then change the start-in location to directly point where you want to start. But note that you'll probably have changed the location of your global config.
 
Do note that on Windows apparent location of ~ can vary depending on the git version, in particular the SDK version vs the regular download version. Some of that is just a matter of how the windows-linux directory mapping was chosen in each case.
 
 
----- Original Message -----
--
You received this message because you are subscribed to the Google Groups "git-for-windows" group.
To unsubscribe from this group and stop receiving emails from it, send an email to git-for-windo...@googlegroups.com.
To post to this group, send email to git-for...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/git-for-windows/4bdc0b02-e10e-41bb-9d60-d465cbf2cc1d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages