Class: PrChangelog::Releases

Inherits:
Object
  • Object
show all
Defined in:
lib/pr_changelog/releases.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(git_proxy = GitProxy.new) ⇒ Releases

Returns a new instance of Releases.



7
8
9
# File 'lib/pr_changelog/releases.rb', line 7

def initialize(git_proxy = GitProxy.new)
  @git_proxy = git_proxy
end

Instance Attribute Details

#git_proxyObject (readonly)

Returns the value of attribute git_proxy.



5
6
7
# File 'lib/pr_changelog/releases.rb', line 5

def git_proxy
  @git_proxy
end

Instance Method Details

#last_releaseObject



11
12
13
# File 'lib/pr_changelog/releases.rb', line 11

def last_release
  sorted_tags.last
end

#last_release_pairObject



15
16
17
# File 'lib/pr_changelog/releases.rb', line 15

def last_release_pair
  sorted_tags.last(2)
end