Skip to content
GitLab
    • GitLab: the DevOps platform
    • Explore GitLab
    • Install GitLab
    • How GitLab compares
    • Get started
    • GitLab docs
    • GitLab Learn
  • Pricing
  • Talk to an expert
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
    • Switch to GitLab Next
    Projects Groups Topics Snippets
  • Register
  • Sign in
  • TortoiseGit TortoiseGit
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributor statistics
    • Graph
    • Compare revisions
    • Locked files
  • Issues 380
    • Issues 380
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 16
    • Merge requests 16
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
    • Test cases
  • Deployments
    • Deployments
    • Releases
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Code review
    • Insights
    • Issue
    • Repository
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • TortoiseGitTortoiseGit
  • TortoiseGitTortoiseGit
  • Issues
  • #86
Closed
Open
Issue created Aug 02, 2015 by Sven Strickroth@mrtuxOwner

Globally sets HOME affecting third-party applications (GNU Emacs)

By pattho... on May 15, 2009 09:39 (imported from Google Code)


What steps will reproduce the problem?

  1. The HOME environment variable exists for all applications launched by
    Windows explorer.

What is the expected output? What do you see instead?
This variable shouldn't be set for child processes that are not Git.

What version of the product are you using? On what operating system?
0.6.2.0 with git 1.6.3.msysgit.0 on Windows Server 2008 x64

Please provide any additional information below.

I use GNU Emacs as my editor and have a specific .emacs that lives in
c:\Users\pat\AppData\Roaming.emacs which seems to be where emacs considers
~/.emacs to be. I can see that most applications are storing their
configuration data in this location on Vista style systems.

Following installation of TortoiseGit 0.6.2.0 my .emacs file is no longer
being read leading to a misconfigured system. This is because there is now
a HOME environment variable defined in the launching process (either
Explorer itself or a cmd shell launched from explorer). This is set to
C:\Users\pat (ie the same as USERPROFILE) where it probably should be using
the value of APPDATA (or the Win32 API call that is the real source of
this). Emacs is now making use of this instead of the original location
because HOME is treated as an override of the system default location.

I recognise that no-one is too sure where HOME really should be on recent
windows systems. %USERPROFILE% and %HOMEDRIVE%%HOMEPATH% would seem to be
likely but as I understand it someone should be calling SHGetFolderPath
with CSIDL_APPDATA which is what emacs is doing in
src/w32.c:init_environment to configure the default value of HOME.

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking