seyhunak/twitter-bootstrap-rails — Issue #110: HAML Layout Generator Error
Author: 1st8
Created: 2012-02-19 20:44:17+00:00
State: open

Hey,

I'm trying to use your Gem, I have the following in my Gemfile (just like described in your readme):

```ruby
gem "twitter-bootstrap-rails", "~> 2.0.1.0"
```

### Problem:
When I run ```rails g bootstrap:layout application fixed``` and have either

``` ruby
gem 'haml-rails'
```

in my Gemfile or

``` ruby
config.generators do |g|
g.template_engine :haml
end
```

in my application.rb I get the following error:

```
(erb):67:in `block in template': undefined local variable or method `flash' for # (NameError)
from (erb):66:in `each'
from (erb):66:in `template'
from /usr/local/rvm/rubies/ruby-1.9.3-p0/lib/ruby/1.9.1/erb.rb:838:in `eval'
from /usr/local/rvm/rubies/ruby-1.9.3-p0/lib/ruby/1.9.1/erb.rb:838:in `result'
from /usr/local/rvm/gems/ruby-1.9.3-p0@global/gems/thor-0.14.6/lib/thor/actions/file_manipulation.rb:111:in `block in template'
...
from /usr/local/rvm/gems/ruby-1.9.3-p0/gems/twitter-bootstrap-rails-2.0.1/lib/generators/bootstrap/layout/layout_generator.rb:29:in `generate_layout'
...
from /usr/local/rvm/gems/ruby-1.9.3-p0@global/gems/railties-3.2.1/lib/rails/generators.rb:170:in `invoke'
from /usr/local/rvm/gems/ruby-1.9.3-p0@global/gems/railties-3.2.1/lib/rails/commands/generate.rb:12:in `'
...
from /usr/local/rvm/gems/ruby-1.9.3-p0@global/gems/railties-3.2.1/lib/rails/commands.rb:29:in `'
from script/rails:6:in `require'
from script/rails:6:in `

'
```

Just wanted to let you know, would be nice to use the generated HAML files like you intended.

Regards
Christoph