LoginSignup
0
0

More than 3 years have passed since last update.

sshでgit pushできないならhttpsにすればいいじゃない!

Posted at

この記事の内容

git pushがしたいだけなのに、謎にsshが接続できなくなった時、の対処法

この記事で扱わないこと

  • sshとhttpsどちらがよいか
  • sshが繋がらなくなった場合の直し方など

解決策

$ git push https://github/path/to/repo <branch>

のようにhttpsを明示的に使ってしまおう。
sshが繋がらなくてもhttpsは大抵使えるはず。
うまくいかないときは、gitconfigで

[url "github:"]
  insteadOf = "https://github.com/"

などしてないか確認しよう!

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