zoukankan      html  css  js  c++  java
  • git上传本地项目到github或者gitlib(两个是一样的)。

    第一步:在github上面创建一个repository 

     点击create就好了。然后会出现下面的页面。

    第三步:打开你所在文件夹,或者是新建的文件夹(用来做仓库的)右键会出现下面  选用git Bash Here 命令行执行。

    点击以后出现下面图片

    然后就是使用刚才我们在github上面创建的仓库 依次执行下面的代码。。。下面是两种形式。(空仓库、项目所在仓库)

    create a new repository on the command line

    echo "# project" >> README.md
    git init
    git add README.md
    git commit -m "first commit"
    git remote add origin 这里是自己的链接
    git push -u origin master

     push an existing repository from the command line

    git remote add origin 自己创建的repository链接
    git push -u origin master
    

     本人用的是第二种比较方便:

    遇到问题分享一下:

      remote origin already exists.

     解决方法:

      

    先删除远程Git仓库用 $ git remote rm origin
    

      

  • 相关阅读:
    工具推荐-css3渐变生成工具
    IE6bug-overflow不能隐藏的bug
    cs3属性操作js
    多级联动下拉菜单(原生js)
    js表单验证大全
    js-运动框架(时间版)
    LeetCode 677. 键值映射
    LeetCode 28. Implement strStr()
    计网学习笔记(5)
    计网学习笔记(4)
  • 原文地址:https://www.cnblogs.com/flyingDragon/p/11283151.html
Copyright © 2011-2022 走看看