In a new Rails 3 app I am having trouble getting the controller
generator to use haml. When I run:
rails g controller home index -p
I get:
create app/controllers/home_controller.rb
error haml [not found]
invoke rspec ...
...
I did this:
* installed the latest version of the haml gem, v2.2.20
* added gem "haml" to Gemfile
* ran bundle install
* ran haml --rails <my_rails_app_dir>. This successfully
installed ./vendor/plugins/haml/init.rb.
* added to application.rb:
config.generators do |g|
g.template_engine :haml
end
I also tried Jacques Crocker's suggestion, no joy:
config/initializers/haml.rb:
Haml.init_rails(binding) if defined?(Haml)
I'm a noob, so I probably just did something simple wrong, but any
suggestions are appreciated.
Thanks...
--
You received this message because you are subscribed to the Google Groups
"Haml" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to [email protected].
For more options, visit this group at http://groups.google.com/group/haml?hl=en.