跳轉到內容

Git 設置用戶信息 配置 Git 用戶名 和 郵箱

查看git配置信息

sh
git config --list

查看git用戶名、密碼、郵箱的配置

sh
git config user.name
git config user.password
git config user.email

設置git用戶名、郵箱的配置

sh
git config --global user.name “用戶名”
git config --global user.email “郵箱”
# 用戶名:建議使用註冊 GitHub 時用的用戶名
# 郵箱:建議使用註冊 GitHub 時用的郵箱

使用 SSH 的方式

sh
ssh-keygen -t rsa -C “郵箱地址”
公鑰:id_rsa.pub
私鑰:id_rsa

最後更新於: