Sha256: 7c0a71b8e91c56faf31204c0adaecaad633e210b2261b5a9f519dfc6fa2e85ef

Contents?: true

Size: 430 Bytes

Versions: 3

Compression:

Stored size: 430 Bytes

Contents

module FeduxOrg
  module Stdlib
    module VersionManagement
      class RubygemVersionFileParser

        attr_reader :version, :modules

        def parse( file )
          data = File.read( file )

          @version = data.match(/(?:VERSION|Version)\s+=\s+["']([^'"]+)["']/) { $1 }
          @modules = data.scan( /^\s*module\s+([A-Z][A-Za-z0-9]+(?:::[A-Z][A-Z0-9a-z]+)*)$/x ).flatten
        end

      end
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
fedux_org-stdlib-0.3.2 lib/fedux_org/stdlib/version_management/rubygem_version_file_parser.rb
fedux_org-stdlib-0.3.0 lib/fedux_org/stdlib/version_management/rubygem_version_file_parser.rb
fedux_org-stdlib-0.2.1 lib/fedux_org/stdlib/version_management/rubygem_version_file_parser.rb