LoginSignup
1
1

More than 3 years have passed since last update.

[git] rsa公開鍵を作成

Last updated at Posted at 2020-04-27
  • 開発環境:macbookpro, terminal

ローカルからGithubにPushした際に出たエラー

git@github.com: Permission denied (publickey).
fatal: Could not read from remote repository.

Please make sure you have the correct access rights

id_rsaを更新する

$ ssh-keygen -t rsa -b 4096 -C "your_email@example.com"

$ pbcopy < ~/.ssh/id_rsa.pub

これでクリップボードにコピーされているので、
Githubの
Settings -> SSH and GPG Keys へ進み緑のボタンから追加。
image.png

pbcopyとするとcatして選択してコピーする手間が省ける。

参考:Permission denied (publickey). fatal: Could not read from remote repository. #23

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