Skip to content

Commit

Permalink
Update next_minor_version method
Browse files Browse the repository at this point in the history
  • Loading branch information
potomak committed Dec 1, 2011
1 parent 017bade commit d528d88
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions lib/tasks/tomatoes.rake
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -61,9 +61,15 @@ def version
end end


def next_minor_version def next_minor_version
TomatoesApp::VERSION.split('.').map do |n| version_array = TomatoesApp::VERSION.split('.')
2 == TomatoesApp::VERSION.split('.').index(n) ? n.to_i+1 : n
end.join('.') if version_array.size > 2
version_array[2] = version_array[2].to_i+1
else
version_array[2] = 1
end

version_array.join('.')
end end


def read_file(filename) def read_file(filename)
Expand Down

0 comments on commit d528d88

Please sign in to comment.