Git之如何上传代码到github上
1. 首先在github上创建一个新的respository.
2. 在github上面的这个respository点击复制github路径:
3. 打开终端,比方定位到桌面:
cd Desktop/
git clone https://github.com/spicyboiledfish/nodeJS-demos.git
此时,桌面会出现一个由github克隆到桌面的文件夹,一般和你设定的respository同名,比方:nodeJS-demos
将你想要上传到github的所有文件及文件夹 拖至 桌面上的这个文件夹 nodeJS-demos
cd nodeJS-demos
git add -A
git commit -m "gzip压缩"
git push
输入github账号及密码上传成功,去github刷新,已全部更新完毕。