下载git,安装 ,打开git bash 命令行,进入代码所在文件夹,
键入如下命令行,
git init
git add README.md
git commit -m "first commit"
git remote add origin https://github.com/lifalin0802/webpack_demo.git
git push -u origin master
Git 提示fatal: remote origin already exists 错误解决办法:
1、先删除远程 Git 仓库(前提: 此工程无用)
$ git remote rm origin
2、再添加远程 Git 仓库
$ git remote add origin https://github.com/lifalin0802/webpack_demo.git
创建分支
创建dev分支
git branch dev