10
7

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

Githubでコミット時に、匿名アカウントになってしまう

Last updated at Posted at 2014-08-01

現象

Githubにcommit+pushしても、自分のアカウントとして認識してくれない。
Githubにログインして直接コミットしたら、ちゃんと認識してくれる。

skitch-スクリーンショット_2014-08-01_14_54_26.png

pushできるってことは、アカウントを認識してるからじゃないの??って不思議になった。

対処方法

commitの詳細ページをみたら、どうやらcommit時のメールアドレスが知らないアドレスだよって言われてる。

skicth^スクリーンショット_2014-08-01_14_54_49.png

つまり、commit時のメールアドレスでアカウントを判定しているようだ。

なので、解決方法としては、

  1. commit時のメールアドレスをGithub側に登録してあげる

  2. commit時のメールアドレスをGithubアカウントに設定済みのメールアドレスに変える

git config (--global) user.email="Githubに登録済みのアドレス"

のいずれかで解決する。

その他

気になった試したのだが、commit時のメールアドレスを他人のものにしてcommitすると、他人のcommitとして登録されてしまう。
Githubの問題というよりGit自体がそういう仕様なのだからしょうがないのだろうか。

10
7
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
10
7

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?