cola

cola

Enjoy Coding Everywhere 👻

Git SSH 設定

github 配置#

切到 .ssh ディレクトリ#

cd ~/.ssh

生成鍵#

ssh-keygen -t rsa -C "[email protected]" -f id_github_rsa

config ファイルを作成#

異なるソースの鍵を管理するため
touch config
以下の内容を入力してください:

Host github.com  
    HostName github.com  
    User git  
    IdentityFile ~/.ssh/id_github_rsa

ssh キーを追加#

公式サイトを開き、id_github_rsa.pub の内容をコピーして、ssh key を追加します

ssh-agent に追加#

ssh-add ~/.ssh/id_github_rsa

テスト#

ssh -T [email protected]

huggingface 配置#

鍵を生成#

ssh-keygen -t ed25519 -C "[email protected]" -f id_huggingface_rsa

config を変更#

Host huggingface.co  
    HostName huggingface.co  
    User git  
    IdentityFile ~/.ssh/id_huggingface_rsa

ssh キーを追加#

公式サイトを開き、id_huggingface_rsa.pub の内容をコピーして、ssh key を追加します

ssh-agent に追加#

ssh-add ~/.ssh/id_huggingface_rsa

テスト#

$ ssh -T [email protected]

読み込み中...
文章は、創作者によって署名され、ブロックチェーンに安全に保存されています。