1
1

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 1 year has passed since last update.

(Mac)SourceTreeで'remote: Invalid username or password.'が出たときの対応

Last updated at Posted at 2023-05-01

remote: Invalid username or password.

Gitで認証情報を変更したときに、システム側で情報を更新しているのにSourceTreeからリモートにアクセスしようとするとremote: Invalid username or password.が発生します。
何度も対応していたりするので、自分用に備忘録として残しておきます。

対処法

SourceTreeに残っている認証情報を削除し、再度認証する。

1. 認証情報の削除

Sourcetree remote: Invalid username or password
を参考に~/Library/Application Support/SourceTree/userName@STAuth-bitbucket.orgを削除し、KeyChainからSourceTreeの認証情報(AccessKey)を削除。

2. SourceTreeでアカウント情報の再設定

SourceTreeの設定 → アカウント(存在すれば削除)
・認証タイプ:OAuth
・ユーザー名を入力
・アカウントを接続
・プロトコル:HTTPS

→ SourceTreeでfetchやpushする
→ 認証情報のダイアログが表示される
→ パスワードを入力して対応完了
スクリーンショット 2023-05-01 11.22.10.png

Note
アクセストークン使うようになってからSourceTreeの認証更に面倒くさくなったなぁ

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

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?