Skip to content

Commit

Permalink
Add option to sort branches before display
Browse files Browse the repository at this point in the history
  • Loading branch information
decklin committed Sep 11, 2012
1 parent 088348c commit 1ded46d
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lib/git-up.rb
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,10 @@ def run
def rebase_all_branches
col_width = branches.map { |b| b.name.length }.max + 1

if config("sort")
branches.sort_by! { |b| b.name }
end

branches.each do |branch|
remote = remote_map[branch.name]

Expand Down

0 comments on commit 1ded46d

Please sign in to comment.