I have a successful Rails 3.0.x project with the following subset of Gems in a Gemfile:
gem "compass" gem "haml" gem "haml-rails" gem "html5-boilerplate"
I tried today to upgrade to Rails 3.1 and keep all the functionality, and I had numerous problems. I have not yet found a configuration that worked for me in production mode, so I am currently working with development mode.
I took the following tips:
- "Upgrade to Rails 3.1" from Railscast: very good, as usual, and told me how to modify
production.rb
, development.rb
and application.rb
to update the configuration of the asset pipeline. But I did not touch the compass, sassi and html5 template. - "Setting up the html template with Rails 3.1" This works best for me, but it doesnβt work because the
ie_html
method ie_html
not available in production mode. Gemfile changes are noted below. - "It is impossible to get Rails 3.1, Compass, Sass, Blueprint, working on Geroku's cedars." This did not work for me at all, I had problems with assets, then it compiles. There, the attempt was to have everything global, because there is a dependency between Compass and the Html-Boilerplate, and the Html-Boilerplate must be global due to the
ie_html
method. - Each attempt to use only certain gems in the
group :assets
block failed. In most cases, the relationship between, for example, compass and sassi, compass and html5 template cannot be fulfilled.
So my question is: is there a working Gemfile that allows you to use Haml, Sass, Compass, Html5-Boilerplate and, of course, Rails 3.1 together?
The new Gemfile is in development mode, but not in production mode:
gem "haml-rails" group :assets do gem 'sass-rails', " ~> 3.1.0" gem 'coffee-rails', "~> 3.1.0" gem 'uglifier' gem 'compass', '~> 0.12.alpha.0' gem "html5-boilerplate" end gem 'jquery-rails'
I tried to create a new Rails 3.1 application and added an image resource there. Everything works fine there, so there is no difference between the development mode and the production mode. In my migrated application, I have the following state:
- Works well in development mode.
- Disable some of the html5 boilerplate stuff to work around production issues.
- Until the precompiled images are found in the operating mode.
source share