-
-
Notifications
You must be signed in to change notification settings - Fork 819
posh-git.psm1 sets $Env:HOME, which screws with Emacs #153
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
The explicit setting of As long as we're using |
Proposal:
|
I have a somewhat related problem, during the Chef Learning exercise (chef-dk) and following this guideline here:
Should I raise another Issue item ? And in the meantime, which one of these should I add to my PS Profile ? |
@PetRose GitHub for Windows only tries to set up its own "Git Shell" with its own To mimic Git Shell in your default # Load posh-git example profile
. (Resolve-Path "$env:LOCALAPPDATA\GitHub\shell.ps1")
. (Resolve-Path "$env:github_posh_git\profile.example.ps1") @ammeep @shiftkey is there "official" guidance on usage of |
@dahlbyk it's very specific to GitHub Desktop, but if you reference it like that it should stay in sync as updates come down. @PetRose GitHub Desktop doesn't change the user or system environment variables (in case you already have Git installed) and so all the heavy-lifting for setting up the environment is done through the Git Shell shortcut. If you really don't want to use Git Shell, I'd suggest @dahlbyk's workaround above. Alternatively, you could install Git for Windows if you're only interested in having the command line tools available (that should address your original issue, and have the Git tools available at a known location). |
I'm going to go ahead and close this since it doesn't seem to be an issue for the vast majority of users. That said, I wouldn't be opposed to adding a note to the README about the module setting |
Modified after reviewing issue #153
Emacs reads your
.emacs
from%HOME%\.emacs
. Documentation: https://www.gnu.org/software/emacs/manual/html_node/emacs/Windows-HOME.htmlIf %HOME% isn't set, then it uses
%APPDATA%\.emacs
.posh-git.psm1
specifically sets$Env:HOME
.So using posh-git causes Emacs to suddenly start loading the
.emacs
from a different location, which is really confusing. It took a while before I tracked down why Emacs was misbehaving, and longer before I tracked the issue down to posh-git.(Otherwise posh-git has been very helpful!)
The text was updated successfully, but these errors were encountered: