Git常见问题分析

24次阅读

共计 357 个字符,预计需要花费 1 分钟才能阅读完成。

当前分支落后于远端分支

hint: Updates were rejected because the tip of your current branch is behind
hint: its remote counterpart. Integrate the remote changes (e.g.
hint: 'git pull ...') before pushing again.
hint: See the 'Note about fast-forwards' in 'git push --help' for details.

当执行 git push 将本地代码向远端推送的时候出现了上面的提示。这个提示的大意是本地代码落后于远端的代码。
导致出现这个提示的原因可能是:

  1. 可能远端有其他同事在你的 commit 之前提交了代码;
  2. 你可能在自己的本地分支进行了回退操作,导致自己的分支落后于远端。

正文完
 0