zoukankan      html  css  js  c++  java
  • git 提交项目代码到码云步骤 以及出现错误解决办法

    1、git init
    2、git remote add origin 项目地址
    3、git add .
    4、git commit -m "注释"
    5、git push origin master

    出现错误 
    $ git push origin master
    To https://gitee.com/heguxin/XXX
     ! [rejected]        master -> master (fetch first)
    error: failed to push some refs to 'https://gitee.com/heguxin/XXX
    hint: Updates were rejected because the remote contains work that you do
    hint: not have locally. This is usually caused by another repository pushing
    hint: to the same ref. You may want to first integrate the remote changes
    hint: (e.g., 'git pull ...') before pushing again.
    hint: See the 'Note about fast-forwards' in 'git push --help' for details.


    解决方法:
    git pull --rebase origin master
    git push origin master

  • 相关阅读:
    Sqlite教程(1) SQLiteOpenHelper
    检查网络连接状态。
    GSON解译Json为DTO
    Okhttp教程 (1)
    HashMap的扩容算法
    回溯算法
    动态规划
    实现自旋锁
    Java堆
    垃圾回收算法总结
  • 原文地址:https://www.cnblogs.com/heguxin/p/10096050.html
Copyright © 2011-2022 走看看