初次下载git后,登录你的账号
git config --global user.name “你的Github名”
git config --global user.email “你的邮箱”
检查是否有密钥
cd ~/.ssh
ls
创建密钥文件,关联到github
ssh-keygen -t rsa -C “你的邮箱”
提交本地仓库到github
// 初始化仓库
git init
// 添加所有文件
git add .
// 提交
git commit -m “first commit”
// 关联远程仓库
git remote add origin git@github.com:CountName/ProjectName.git
// 拉取
git pull --rebase origin master
// 推送
git push -u origin master
克隆github项目到本地
git clone https://github.com/86K/UnityGameFramework
// 解除与远程库的关联
git remote rm origin
// 图形化工具推荐
windows:TortoiseGit
macOS:Tower