Class: Rails::Generator::Commands::Base
- Inherits:
-
Object
- Object
- Rails::Generator::Commands::Base
- Defined in:
- lib/startups.rb
Instance Method Summary collapse
Instance Method Details
#route_code(route_options) ⇒ Object
12 13 14 15 16 17 18 |
# File 'lib/startups.rb', line 12 def route_code() if .is_a? Hash "map.#{[:name]} '#{[:name]}', :controller => '#{[:controller]}', :action => '#{[:action]}'" else .to_s.gsub("\n ","\n").strip end end |
#route_code_log_message(route_options) ⇒ Object
19 20 21 22 23 24 25 26 |
# File 'lib/startups.rb', line 19 def () code = route_code() if code.index "\n" code = code[0,code.index("\n")] code = "#{code} ... end" if code.index ' do ' end code end |