Module: Otto::VERSION

Defined in:
lib/otto.rb

Class Method Summary collapse

Class Method Details

.inspectObject



16
17
18
# File 'lib/otto.rb', line 16

def self.inspect
  to_s
end

.load_configObject



19
20
21
22
# File 'lib/otto.rb', line 19

def self.load_config
  require 'yaml'
  @version ||= YAML.load_file(File.join(LIB_HOME, '..', 'VERSION.yml'))
end

.to_sObject



12
13
14
15
# File 'lib/otto.rb', line 12

def self.to_s
  load_config
  [@version[:MAJOR], @version[:MINOR], @version[:PATCH]].join('.')
end