Class: Piano::Base
- Inherits:
-
Sinatra::Base
- Object
- Sinatra::Base
- Piano::Base
- Defined in:
- lib/piano.rb,
lib/piano/routes.rb
Class Method Summary collapse
Class Method Details
.i18n! ⇒ Object
27 28 29 30 31 32 33 34 35 36 37 |
# File 'lib/piano.rb', line 27 def self.i18n! return unless Dir.exists? self.i18n_path dir = Dir.new self.i18n_path i18n_files = [] dir.each do |file| if file.end_with?(".yml") or file.end_with?(".yaml") i18n_files << "#{dir.path}/#{file}" end end I18n.load_path = i18n_files end |
.play! ⇒ Object
39 40 41 |
# File 'lib/piano.rb', line 39 def self.play! self.run! end |