Merge branch 'maint'
[gitweb.git] / contrib / fast-import / git-p4
index e3404ca853c8b54f1a0c64be7038d282746652a7..1f5a56ee7ffcedb854d84023fdf61570dcffe67e 100755 (executable)
@@ -901,7 +901,8 @@ class P4Sync(Command):
                            % (labelDetails["label"], change))
 
     def getUserCacheFilename(self):
-        return os.environ["HOME"] + "/.gitp4-usercache.txt"
+        home = os.environ.get("HOME", os.environ.get("USERPROFILE"))
+        return home + "/.gitp4-usercache.txt"
 
     def getUserMapFromPerforceServer(self):
         if self.userMapFromPerforceServer: