Can “git pull --all” update all my local branches?

前端 未结 25 2402
失恋的感觉
失恋的感觉 2020-11-22 16:33

I often have at least 3 remote branches: master, staging and production. I have 3 local branches that track those remote branches.

Updating all my local branches is

25条回答
  •  无人及你
    2020-11-22 17:34

    In fact, with git version 1.8.3.1, it works:

    [root@test test]# git br
    * master
      release/0.1
      update
    [root@test test]# git pull --rebase
    remote: Enumerating objects: 9, done.
    remote: Counting objects: 100% (9/9), done.
    remote: Compressing objects: 100% (9/9), done.
    remote: Total 9 (delta 2), reused 0 (delta 0)
    Unpacking objects: 100% (9/9), done.
    From http://xxx/scm/csdx/test-git
       d32ca6d..2caa393  release/0.1 -> origin/release/0.1
    Current branch master is up to date.
    [root@test test]# git --version
    git version 1.8.3.1
    

    In master branch, you can update all other branches. @Cascabel

    I do not know which version break/fix it, in 2.17(which i use), it can work.

提交回复
热议问题