How do I list all remote branches in Git 1.7+?

后端 未结 19 2272
轮回少年
轮回少年 2020-12-02 03:14

I\'ve tried git branch -r, but that only lists remote branches that I\'ve tracked locally. How do I find the list of those that I haven\'t? (It doesn\'t matter

19条回答
  •  渐次进展
    2020-12-02 03:54

    TL;TR;

    This is the solution of your problem:

    git remote update --prune    # To update all remotes
    git branch -r                # To display remote branches
    

    or:

    git remote update --prune    # To update all remotes
    git branch              # To display all branches
    

提交回复
热议问题