0
0

More than 1 year has passed since last update.

Git pushが失敗(SourceTree)→Gitのバージョンをあげて解決

Last updated at Posted at 2022-07-18

SourceTreeを使ってpushしようとしたら下記エラーになった。

git -c diff.mnemonicprefix=false -c core.quotepath=false --no-optional-locks push -v --tags yLineGame master:master
Logon failed, use ctrl+c to cancel basic credential prompt.
Pushing to https://github.com/cicular/yLineGame.git
エラー終了しました。エラーの内容は上記をご覧ください。

ローカルへのコミットは成功するが、プッシュができない。
つい1時間半前まではできていたのに。。

上記エラーメッセージとともに認証を求めるポップアップが表示されて、正しいログイン情報を入力しているのにダメ。何回やっても変わらない。

SourceTreeで「ツール」->「オプション」->「認証」を確認しても、しっかりアカウント情報は登録されている。

対応

Gitのバージョンが古そうなのでアップデート。

C:\Users\circu>git --version
git version 2.28.0.windows.1


git update-git-for-windows

C:\Users\circu>git --version
git version 2.37.1.windows.1

SourceTreeから再度pushを試みると、認証許可を求められた。

git.png

「Authorize…」を押すと、push成功した。

0
0
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
0
0