Sha256: 11ee0e17d41fa907f37440177145d34031b9804ffc00956a66b5126a6a515ce5

Contents?: true

Size: 463 Bytes

Versions: 4

Compression:

Stored size: 463 Bytes

Contents

module Yaks
  module Changelog
    module_function

    def current
      versions[Yaks::VERSION]
    end

    def versions
      markdown.split(/(?=###\s*[\d\w\.]+\n)/).each_with_object({}) do |section, hsh|
        version = section.each_line.first[/[\d\w\.]+/]
        log     = section.each_line.drop(1).join.strip
        hsh[version] = log
      end
    end

    def markdown
      Pathname(__FILE__).join('../../../../CHANGELOG.md').read
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
yaks-0.13.0 lib/yaks/changelog.rb
yaks-0.12.0 lib/yaks/changelog.rb
yaks-0.11.0 lib/yaks/changelog.rb
yaks-0.10.0 lib/yaks/changelog.rb