A place for spare thoughts


Troubleshooting: Git Home directory

Filed under: git — Ivan Danilov @ 08:10

After installing GitExtensions it starts to show me error each time complaining about lack of permissions to get .gitconfig from u://.gitconfig. Wow! I didn’t even have a U drive. As it is not very likely that everybody who uses GitExtensions (GE for short further) has U drive – this path should be set somewhere.

When you run GE -> Settings you could see on ‘Git’ tab some text about home directory where GE search for .gitconfig. Well, actually it says that if %HOME% environment dir is present – it will look for .gitconfig there.

So I went to Computer -> Properties -> Advanced system settings -> Environment variables… -> System variables and set there variable HOME to some local path.

But after starting GE again – it still can’t find .gitconfig.

Well, it costed me getting sources and some debugging to figure out that HOME variable is being looked only in _user_ variables, not system ones. It makes sense actually, because HOME is home directory of current user. But I was so accustomed to set system vars, that did it almost automatically.

UPDATE: There’s another issue exists. Make sure %HOME% is not equal to Git’s base directory. The thing is msysgit treats C:\Program Files (x86)\Git (or wherever you have it installed) as root / and adds /bin to it literally – similarly to command PATH=$HOME/bin:$PATH. Thus if your %HOME% is C:\Program Files (x86)\Git you’ll have $PATH starting with //bin: which is obviously incorrect.
This can lead to inability to find extensions like git-tfs.exe and others.


Leave a Comment »

No comments yet.

RSS feed for comments on this post. TrackBack URI

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

Create a free website or blog at WordPress.com.

%d bloggers like this: