1
/home/eduardo/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/compass-h5bp-0.1.1/lib/compass/h5bp.rb:5:in `<module:H5bp>': uninitialized constant Compass::Frameworks (NameError)

这是我的 Gemfile:

source 'https://rubygems.org'

gem 'rails', '4.0.0.beta1'
gem 'sqlite3'
gem 'turbolinks'
gem 'jbuilder', '~> 1.0.1'

group :test, :development do
  gem 'rspec-rails', '~> 2.0'
end

group :assets do
  gem 'sass-rails',   '~> 4.0.0.beta1'
  gem 'coffee-rails', '~> 4.0.0.beta1'
  gem 'haml-rails'
  gem 'uglifier', '>= 1.0.3'

  gem 'compass-h5bp'
end

gem 'html5-rails'
gem 'jquery-rails'

group :test do
  gem 'capybara'
end

# To use ActiveModel has_secure_password
# gem 'bcrypt-ruby', '~> 3.0.0'

# Use unicorn as the app server
# gem 'unicorn'

# Deploy with Capistrano
# gem 'capistrano', group: :development

# To use debugger

我不知道是什么导致了这个错误。当我尝试运行时出现错误:

rails generate html5:install

这是项目:https ://github.com/sporkd/html5-rails

我尝试了一些在 Google 上找到的东西,但没有一个真正奏效。

4

2 回答 2

3

在 compass-h5bp之前使用 compass-rails它可以工作(rails 3.2.13,ruby 2.0)

group :assets do
  gem 'sass-rails'
  gem 'coffee-rails'

  # See https://github.com/sstephenson/execjs#readme for more supported runtimes
  # gem 'therubyracer', :platforms => :ruby

  gem 'uglifier'
  gem 'compass-rails'
  gem 'compass-h5bp'
end
于 2013-05-08T09:38:20.857 回答
0

将 compass-rails gem 添加到资产组为我解决了这个问题。

于 2013-04-27T00:03:59.287 回答