Skip to content

Commit

Permalink
Merge pull request #223 from stevdiaz/master
Browse files Browse the repository at this point in the history
Better performance of gl branch -r
  • Loading branch information
spderosso committed Dec 3, 2019
2 parents 7b8785f + f9187d3 commit ce7f069
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions gitless/cli/gl_branch.py
Expand Up @@ -118,8 +118,10 @@ def _do_list(repo, list_remote, v=False):

if list_remote:
for r in sorted(repo.remotes, key=lambda r: r.name):
for b in r.lookupall_branches():
pprint.item(' {0}'.format(colored.yellow(str(b))))
branches = r.lookupall_branches() if v else r.listall_branches()
b_remote = '' if v else r.name + '/'
for b in branches:
pprint.item(' {0}'.format(colored.yellow(b_remote + str(b))))
if v:
pprint.item(' ➜ head is {0}'.format(pprint.commit_str(b.head)))

Expand Down

0 comments on commit ce7f069

Please sign in to comment.