1

关于 Drupal Omega 子主题的创建。我刚刚安装了一个新的子主题并运行了捆绑安装。

我的主题是想要导入以下库

// Import external libraries.
@import "compass";
@import "breakpoint";
@import "singularitygs";
@import "toolkit-no-css";
@import "toolkit";

在运行 bundle exec guard 或 drush-ogrd 时,我得到以下编译错误。我以前做过这个没有问题,并且怀疑某个地方的宝石不兼容,但我真的不知道从这里去哪里。任何指针?


Pauls-MacBook-Pro:ambient pauldriver$ bundle exec guard
]    error sass/ambient.no-query.scss (Line 3 of sass/ambient.styles.scss: File to import not found or unreadable: breakpoint.
Load paths:
  /Users/pauldriver/Sites/ambientair/sites/all/themes/ambient/sass
  Compass::SpriteImporter
  /Users/pauldriver/Sites/ambientair/sites/all/themes/ambient/sass
  /Users/pauldriver/.rvm/gems/ruby-1.9.3-p547@omega.ambient/gems/compass-core-1.0.0/stylesheets
  /Users/pauldriver/.rvm/gems/ruby-1.9.3-p547@omega.ambient/gems/susy-2.1.3/sass
  /Users/pauldriver/.rvm/gems/ruby-1.9.3-p547@global/gems/compass-normalize-1.5/stylesheets
  /Users/pauldriver/.rvm/gems/ruby-1.9.3-p547@global/gems/compass-rgbapng-0.2.1/lib/stylesheets
  /Users/pauldriver/.rvm/gems/ruby-1.9.3-p547@omega.ambient/gems/toolkit-2.5.2/stylesheets
  Sass::Globbing::Importer)
    error sass/ambient.normalize.scss (Line 8: File to import not found or unreadable: toolkit/border-box.
Load paths:
  /Users/pauldriver/Sites/ambientair/sites/all/themes/ambient/sass
  Compass::SpriteImporter
  /Users/pauldriver/Sites/ambientair/sites/all/themes/ambient/sass
  /Users/pauldriver/.rvm/gems/ruby-1.9.3-p547@omega.ambient/gems/compass-core-1.0.0/stylesheets
  /Users/pauldriver/.rvm/gems/ruby-1.9.3-p547@omega.ambient/gems/susy-2.1.3/sass
  /Users/pauldriver/.rvm/gems/ruby-1.9.3-p547@global/gems/compass-normalize-1.5/stylesheets
  /Users/pauldriver/.rvm/gems/ruby-1.9.3-p547@global/gems/compass-rgbapng-0.2.1/lib/stylesheets
  /Users/pauldriver/.rvm/gems/ruby-1.9.3-p547@omega.ambient/gems/toolkit-2.5.2/stylesheets
  Sass::Globbing::Importer)
    error sass/ambient.styles.scss (Line 3: File to import not found or unreadable: breakpoint.
Load paths:
  /Users/pauldriver/Sites/ambientair/sites/all/themes/ambient/sass
  Compass::SpriteImporter
  /Users/pauldriver/Sites/ambientair/sites/all/themes/ambient/sass
  /Users/pauldriver/.rvm/gems/ruby-1.9.3-p547@omega.ambient/gems/compass-core-1.0.0/stylesheets
  /Users/pauldriver/.rvm/gems/ruby-1.9.3-p547@omega.ambient/gems/susy-2.1.3/sass
  /Users/pauldriver/.rvm/gems/ruby-1.9.3-p547@global/gems/compass-normalize-1.5/stylesheets
  /Users/pauldriver/.rvm/gems/ruby-1.9.3-p547@global/gems/compass-rgbapng-0.2.1/lib/stylesheets
  /Users/pauldriver/.rvm/gems/ruby-1.9.3-p547@omega.ambient/gems/toolkit-2.5.2/stylesheets
  Sass::Globbing::Importer)
Compilation failed in 3 files.

我的 config.rb 文件包含以下内容

##
## This file is only needed for Compass/Sass integration. If you are not using
## Compass, you may safely ignore or delete this file.
##
## If you'd like to learn more about Sass and Compass, see the sass/README.txt
## file for more information.
##

# Default to development if environment is not set.
saved = environment
if (environment.nil?)
  environment = :development
else
  environment = saved
end

# Location of the theme's resources.
css_dir = "css"
sass_dir = "sass"
images_dir = "images"
generated_images_dir = images_dir + "/generated"
javascripts_dir = "js"

# Require any additional compass plugins installed on your system.
require 'compass-normalize'
require 'rgbapng'
require 'toolkit'
require 'susy'
require 'sass-globbing'

##
## You probably don't need to edit anything below this.
##

# You can select your preferred output style here (:expanded, :nested, :compact
# or :compressed).
output_style = (environment == :production) ? :expanded : :nested

# To enable relative paths to assets via compass helper functions. Since Drupal
# themes can be installed in multiple locations, we don't need to worry about
# the absolute path to the theme from the server omega.
relative_assets = true

# Conditionally enable line comments when in development mode.
line_comments = (environment == :production) ? false : true

# Output debugging info in development mode.
sass_options = (environment == :production) ? {} : {:debug_info => true}

# Add the 'sass' directory itself as an import path to ease imports.
add_import_path 'sass'
4

1 回答 1

1

Omega 4 的最新开发版本似乎修复了大多数不兼容的宝石问题。感谢您对此的帮助。

于 2014-08-26T12:22:35.223 回答