Git warning: unable to access 'P:\/.gitconfig': Invalid argument

Chris G. picture Chris G. · Feb 8, 2013 · Viewed 36.9k times · Source

I am just testing git. I ran the following command:

git config user.email "[email protected]"

I now get this when git status and others:

C:\gitg\g1>git status
warning: unable to access 'P:\/.gitconfig': Invalid argument
warning: unable to access 'P:\/.gitconfig': Invalid argument
warning: unable to access 'P:\/.gitconfig': Invalid argument
# On branch master
warning: unable to access 'P:\/.gitconfig': Invalid argument
nothing to commit, working directory clean

C:\gitg\g1>

Answer

Daniel Hilgarth picture Daniel Hilgarth · Mar 19, 2013

I just encountered this error.
Executing set HOMEPATH in the command line gave this output:

HOMEPATH=\

Simply deleting this environment variable via set HOMEPATH= fixed the problem.