按照这些说明使用Bundler运行Foundation的多个版本后,我成功创建了一个依赖于3.2.5
的新项目。
以下是我的Gemfile:
source "https://rubygems.org"
gem "zurb-foundation", "3.2.5"
gem "compass"
我接着运行了bundle exec compass create . -r zurb-foundation --using foundation
,它创建了我的Gemfile.lock文件:
GEM
remote: https://rubygems.org/
specs:
chunky_png (1.2.7)
compass (0.12.2)
chunky_png (~> 1.2)
fssm (>= 0.2.7)
sass (~> 3.1)
fssm (0.2.9)
modular-scale (1.0.6)
compass (>= 0.12.1)
sass (>= 3.2.0)
sassy-math (>= 1.5)
rake (10.0.3)
sass (3.2.5)
sassy-math (1.5)
compass (~> 0.11)
zurb-foundation (3.2.5)
compass (>= 0.12.2)
modular-scale (= 1.0.6)
rake
sass (>= 3.2.0)
PLATFORMS
ruby
DEPENDENCIES
compass
zurb-foundation (= 3.2.5)
但是 - 在尝试使用Codekit编译时,我遇到了以下问题:
Compass was unable to compile one or more files in the project:
error app.scss (Line 1 of _settings.scss: File to import not found or unreadable: foundation/common/ratios.
Load paths:
/Users/chester/Sites/f3.2.5test/sass
/Library/Ruby/Gems/1.8/gems/compass-0.12.2/frameworks/blueprint/stylesheets
/Library/Ruby/Gems/1.8/gems/compass-0.12.2/frameworks/compass/stylesheets
/Library/Ruby/Gems/1.8/gems/zurb-foundation-4.0.5/scss
Compass::SpriteImporter)
overwrite app.css
(This action was triggered by a change to _settings.scss)
从外观上看,似乎仍在尝试从4.0.5
获取某些内容。顺便提一下,我在尝试升级Foundation时收到了这条消息:
sudo gem update zurb-foundation
Updating installed gems
Updating zurb-foundation
Fetching: zurb-foundation-4.0.5.gem (100%)
Successfully installed zurb-foundation-4.0.5
Installing RDoc documentation for zurb-foundation-4.0.5
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/rdoc/rdoc.rb:280: warning: conflicting chdir during another chdir block
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/rdoc/rdoc.rb:287: warning: conflicting chdir during another chdir block
Installing ri documentation for zurb-foundation-4.0.5
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/rdoc/rdoc.rb:280: warning: conflicting chdir during another chdir block
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/rdoc/rdoc.rb:287: warning: conflicting chdir during another chdir block
Done installing documentation for zurb-foundation after 0 seconds
Gems updated: zurb-foundation
但实际上文件似乎已经成功安装了 gem list
bundler (1.3.2)
chunky_png (1.2.7)
compass (0.12.2)
fssm (0.2.10, 0.2.9)
modular-scale (1.0.6)
rake (10.0.3)
rubygems-update (2.0.2, 1.8.24)
sass (3.2.7, 3.2.5)
sassy-math (1.5)
zurb-foundation (4.0.5, 3.2.5, 3.2.4)
我能够创建/使用F4项目,但出现了某些F3项目仍然引用F4的问题(并出现了那些难以理解的错误)。非常感谢任何帮助。谢谢!
更新
这似乎是Codekit的问题——因为使用标准的“bundle exec compass watch”似乎可以正常工作。开发者没有回复我对此提出的问题——所以任何其他“已经”成功的人分享他们的见解将会让我感激不尽。谢谢。