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 3 years have passed since last update.

AWS Git Codecommit で環境ごとにログイン情報を分ける方法(windows)

Last updated at Posted at 2021-01-20

前提

OS: windows 10

課題

windows資格情報にログイン情報を登録するが、Codecommitの場合、環境ごとのURLが一緒になってしまう。
結果、1つの環境しか登録できない。

それを防ぐため、configファイルを編集し別ものとして登録する。

方法

資格情報を消す

既に登録されているものが優先されて使用されてしまうため、資格情報を消します。

  1. windowsタスクバーの検索から、資格情報にアクセス
    image.png

  2. windows資格情報に行き、codecommitのURLが振られている資格情報を削除する。
    image.png
    image.png

configファイルの編集

プロジェクトごとの.git/config内を追加編集する。

例. AWSの環境番号が12345678の場合
以下を追加する。

.git/config
[credential]
	namespace = 12345678

ログイン情報の設定

  1. gitクライアント等でfetchコマンドを入力する。
  2. 資格情報を入力する窓が表示される。設定値を入力する。

確認

資格情報に、指定された番号で登録されていればOK
image.png

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?