2017-04-15 13 views
2

ローカル端末から新しいgithubアカウントリポジトリにコミットできません。ローカルgithubアカウント情報を更新する

credential.helper=osxkeychain 
core.editor=/usr/bin/vim 
core.autocrlf=input 
user.name=<new-account-name> 
user.email=<new-email> 
push.default=simple 
core.repositoryformatversion=0 
core.filemode=true 
core.bare=false 
core.logallrefupdates=true 
core.ignorecase=true 
core.precomposeunicode=true 
remote.origin.url=https://github.com/<new-account-name>/22c.git 
remote.origin.fetch=+refs/heads/*:refs/remotes/origin/* 

は、他の何かがあるなら、私に知らせて、助けてくれてありがとう:私は私の世界 'のgit config' を更新しました

remote: Permission to <new-account-name>/22c.git denied to <old-account-name>. 

は、次のことを明らかにし

git config --list 

をsettings`それは問題を解決するのに役立ちます

答えて

2

ここで、user.name=<new-account-name>は認証とは関係ありませんGitHubに<new-account-name>として:それはコミットに関連した著作権です。

あなたの資格情報は、おそらくgit credential helper osxkeychainにキャッシュされています。そこに更新する必要があります。
Updating credentials from the OSX Keychain」を参照してください。コマンドラインで:それは成功したなら

git credential-osxkeychain erase 
host=github.com 
protocol=https 
[Press Return] 

、何も出て印刷されません。
これが動作することをテストするには、GitHubからリポジトリを複製してみてください。ユーザー名/パスワードの入力を求めるメッセージが表示された場合は、キーチェーンのエントリが削除されました。

How do you reset the stored credentials in git credential-osxkeychain?」でさらにご覧ください。

0

問題は私のosxkeychainにありました。よく文書化されたソリューションについてはhereをクリックしてください。

関連する問題