1
0

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.

GitLabのssh登録にpbcopyが便利すぎた

1
Posted at

結論

cat ~/.ssh/id_rsa.pub | pbcopy

上記のコマンドを実行すれば、生成した公開鍵の中身をクリップボードにコピーすることができます。そして、コピーした内容をGitLabのsshの公開鍵の登録テキストフィールドにペーストすれば簡単にできます。

ssh公開鍵生成

ssh-keygen -t ed25519 -C "<comment>"

上記のコメントの部分には任意のテキストを入力してください。

今回は公式のページによるとRSAよりセキュリティが高いと言われているED25519を生成する想定でいます。

参考記事

SSHキーを使ってGitLabと通信します。 | GitLab

Macな人は pbcopy が便利 - Qiita

macOSのターミナルでのクリップボード操作(pbcopy/pbpaste)

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

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?