module ParseAChangelog
Public Class Methods
parse(file_path)
click to toggle source
# File lib/parse_a_changelog.rb, line 8 def parse(file_path) file = File.read(file_path) parser = KeepAChangelogParser.new result = parser.parse(file) unless result raise parser_error( parser.failure_line, parser.failure_column, parser.failure_reason ) end result end
parser_error(line, column, reason)
click to toggle source
# File lib/parse_a_changelog.rb, line 22 def parser_error(line, column, reason) ParseError.new("line #{line}, column #{column}: #{reason}") end