Skip to content
This repository was archived by the owner on Dec 15, 2022. It is now read-only.

Github sets git global user.email to repo's local user.email #2628

Closed
beingmrkenny opened this issue Feb 18, 2021 · 2 comments
Closed

Github sets git global user.email to repo's local user.email #2628

beingmrkenny opened this issue Feb 18, 2021 · 2 comments

Comments

@beingmrkenny
Copy link

Description

I use git at work where the global ~/.gitconfig has a user.email of, let's say, [email protected].

I also use a personal github repo with all my dotfiles where all commits need a user.email of, let's say [email protected]. I have set the /repo/.git/config in this repo to a user.email of [email protected].

I find when I open this repo in atom, with github enabled, it resets my global user.email to [email protected], which is a huge inconvenience since I have to manually change it back every time I open this local repo.

When github is disabled, this doesn't happen.

Steps to Reproduce

  1. Set your global user.email to one email address with git config --global user.email [email protected]
  2. Set the local user.email to a different email address when the working dir is that repo with git config user.email [email protected]
  3. Open the repo with atom .
  4. View your global .gitconfig with less ~/.gitconfig — the user.email will now be [email protected].

Expected behavior:

There should be no change to the global .gitconfig, regardless of what the repo's git config is set to

Actual behavior:

Global git config user.email is changed

Reproduces how often:

100%

Versions

github 0.36.2

Atom : 1.54.0
Electron: 6.1.12
Chrome : 76.0.3809.146
Node : 12.4.0

apm 2.5.2
npm 6.14.8
node 12.4.0 x64
atom 1.54.0
python 2.7.15
git 2.29.2

macOS 10.15.7

@smashwilson
Copy link
Contributor

Duplicate of #2622 and #2557 and probably a few others that I can't find right now. Already fixed by #2587. The latest package version lets you choose explicitly:

image

Try switching to Atom Nightly if you want this behavior sooner rather than later!

@beingmrkenny
Copy link
Author

@smashwilson Ah that's great news, this has been happening for a while now :) Any estimate as to when atom might release this?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants