工作原理 / 流程:
Workspace:工作区
Index / Stage:暂存区
Repository:仓库区(或本地仓库)
Remote:远程仓库
create a new repository on the command line:
echo “# xxx” >> README.md
git init
git add README.md
git commit -m “first commit”
git remote add origin https://github.com/userName/repositoryName.git
git push -u origin master
问题1:remote origin already exists.
解决:git remote rm origin
问题2:.gitignore无效
解决:方法及.gitignore规则
git使用教程