码迷,mamicode.com
首页 > 其他好文 > 详细

本地文件夹变远程仓库并且提交Github

时间:2017-10-30 18:20:10      阅读:184      评论:0      收藏:0      [点我收藏+]

标签:comm   obj   root   branch   分支   zed   vue   github   sed   

//初始化本地仓库
$ git init Initialized empty Git repository in C:/Users/root/Desktop/vue-music/.git/ root@DESKTOP-S1JNUOH MINGW64 ~/Desktop/vue-music (master)
//添加README.md 描述文件 $ git add README.md root@DESKTOP-S1JNUOH MINGW64 ~/Desktop/vue-music (master)
//提交到本地仓库 $ git commit -m "frist commit!" [master (root-commit) f0b9293] frist commit! 1 file changed, 21 insertions(+) create mode 100644 README.md root@DESKTOP-S1JNUOH MINGW64 ~/Desktop/vue-music (master)
//推送到远程仓库 $ git remote add origin https://github.com/Sunnshino/vue-music.git root@DESKTOP-S1JNUOH MINGW64 ~/Desktop/vue-music (master)
//推送到主分支 $ git push -u origin master Counting objects: 3, done. Delta compression using up to 4 threads. Compressing objects: 100% (2/2), done. Writing objects: 100% (3/3), 514 bytes | 0 bytes/s, done. Total 3 (delta 0), reused 0 (delta 0) To https://github.com/Sunnshino/vue-music.git * [new branch] master -> master Branch master set up to track remote branch master from origin.

  

本地文件夹变远程仓库并且提交Github

标签:comm   obj   root   branch   分支   zed   vue   github   sed   

原文地址:http://www.cnblogs.com/cisum/p/7755425.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!