我如何执行 git pull 以便它更新工作中的文件

发布于 2024-08-29 03:52:21 字数 60 浏览 3 评论 0原文

当我执行 git pull origin master 时,它似乎没有更新 git 存储库文件夹中的文件。

When I do git pull origin master, it does not seem to update the files in the folder of the git repository.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

落花随流水 2024-09-05 03:52:21

一些建议,

尝试使用 git pull -v origin master 来查看详细版本是否产生任何线索。

如果您可以克隆您的存储库并使其处于任何 git pull 之前的状态:

    current=`git rev-parse HEAD`
    git pull origin
    git diff $current..
     git diff ...FETCH_HEAD

A few suggestions,

Try a git pull -v origin master to see if the verbose version produces any clue.

If you can clone your repo and get it in a state before any git pull:

    current=`git rev-parse HEAD`
    git pull origin
    git diff $current..
  • try a git fetch origin master, which is equivalent to "git fetch origin master:", not to "git fetch origin master:master" (i.e.: it stores fetched value of 'master' branch (of remote 'origin') in FETCH_HEAD, and not in 'master' branch or remote-tracking 'remotes/origin/master' branch.
    That means you can try and detect if any changes are to be introduced by that fetch:
     git diff ...FETCH_HEAD
无所的.畏惧 2024-09-05 03:52:21

你可以骚扰 gremlinz。

git-pull 应该获取远程更改并将它们合并到当前分支中。

要验证更改是否已合并,请执行 git log 来验证您期望的修订是否位于本地分支中。

来自 git-pull doco

接下来将远程分支合并到当前分支:

$ git pull origin next

You can haz gremlinz.

git-pull is supposed to fetch the remote changes and merge them into the current branch.

To verify that the changes have been merged, do git log to verify that the revisions that you are expecting are in your local branch.

From git-pull doco:

Merge into the current branch the remote branch next:

$ git pull origin next

递刀给你 2024-09-05 03:52:21

也许您没有对遥控器进行任何更改(或者维护它的人没有更新它)。

也许您有多个遥控器,并且您对哪一个pull 应该获取表单感到困惑。

Maybe you didn't make any change to the remote (or who ever maintains it didn't update it).

Maybe you have more than one remote and you're confused about which one pull is supposed to fetch form.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文