git常用命令

拉取代码

拉取指定分支

git clone -b drizzle https://github.com/RobinWM/shipany-template-one.git my-shipany-project

同步代码

git clone https://github.com/RobinWM/shipany-template-one.git
git remote rm origin
git remote add upstream https://github.com/shipanyai/shipany-template-one.git
git remote add origin <your-repository-url>
git pull upstream main

代理

git config --global --unset http.proxy
git config --global http.proxy http://127.0.0.1:7890

配置

git config user.name "RobinWM"
git config user.email "v517649974769@gmail.com"

密钥生成

ssh-keygen -t ed25519 -C "v517649974769@gmail.com"