git+sshでデフォルト(id_rsa)以外のキーファイルを指定したい場合 - yukke.org Diary
~/.ssh/configでgitで使用するHOSTを登録してIdentityFileを指定すればよい。
例
~/.ssh/config
Host Foo
HostName example.com
User foo
IndentityFIle ~/.ssh/id_other
$ git remote add origin user@Foo:/your/repository.git


コメントする