application.css.scss没有加载所需的文件

时间:2015-01-13 17:40:38

标签: ruby-on-rails ruby ruby-on-rails-3 asset-pipeline

我正在建立一个传统的Rails 3项目,ruby 1.9.3。

资产管道无效。

我的application.css.scss并没有真正导入它的导入。

这是我的development.rb文件:

Proj::Application.configure do
  config.cache_classes = false
  config.serve_static_assets = false
  # Show full error reports and disable caching
  config.consider_all_requests_local       = true

  # Do not compress assets
  config.assets.compress = false 
  config.assets.compile = false
  config.assets.debug = true
end

这是我的Gemfile

source "http://rubygems.org"

#gem 'pg'
gem 'mysql2'
gem 'rails', '3.2.3'
gem "authlogic", "3.0.3"
gem 'carrierwave'
gem 'rmagick'
gem 'fog'
gem "will_paginate", "~> 3.0"
gem "friendly_id", "~> 3.2.1"
gem 'activemerchant'
gem 'delayed_job_active_record'
gem 'i18n', '0.6.0'
gem 'ajaxful_rating_jquery', :git => "git://github.com/lshemesh/ajaxful_rating_jquery.git"
#gem 'acts_as_state_machine'
gem 'dynamic_form'
gem 'heroku'
gem 'jquery-rails'
gem 'state_machine'
#gem 'bartt-ssl_requirement', :require => 'ssl_requirement'
gem 'faker', '0.3.1'
gem 'populator', '0.2.5'
gem 'execjs'
gem 'daemons'
gem 'rack-ssl-enforcer'
gem 'braintree'
gem 'flag_shih_tzu'
gem 'omniauth-facebook'
gem 'omniauth-google-oauth2'
gem 'honeypot-captcha'
gem 'famfamfam_flags_rails'
gem 'language_list'
gem 'simple_captcha2', require: 'simple_captcha'
gem 'haml'
gem 'haml-rails'

# group :development do
#   gem 'thin'
# end

group :production do
  gem 'unicorn'
end

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

group :test do
  gem 'cucumber-rails', require: false
  gem 'database_cleaner'
  gem 'poltergeist'
  gem 'factory_girl'
  # gem 'autotest-rails'
  gem 'factis'
  gem 'email_spec'
end

group :assets do
  gem 'coffee-rails'
  gem 'uglifier'
end

我的application.rb

上有以下内容
config.assets.enabled = true

这是我的application.css.scss

/*
 *= require_self
 *= require_tree .
 *= require famfamfam-flags
*/

但require_tree不起作用。

如果我去浏览器并检查我的application.css文件,我会看到它的内容(需要声明),而不是导入其他文件的空文件。

有任何帮助吗? 感谢

0 个答案:

没有答案