不能再运行指南针了

时间:2014-01-19 23:40:34

标签: ruby gem sass compass-sass

我在运行罗盘命令时遇到问题(从今天开始)。几个小时前它完美地工作了

操作系统: 10.9.1(小牛队)

Ruby: ruby 2.0.0p247 (2013-06-27 revision 41674) [universal.x86_64-darwin13]

我今天安装了scss-lint

sudo gem install scss-lint

返回

Fetching: colorize-0.5.8.gem (100%)
Successfully installed colorize-0.5.8
Fetching: sass-3.3.0.rc.1.gem (100%)
Successfully installed sass-3.3.0.rc.1
Fetching: scss-lint-0.17.1.gem (100%)
Successfully installed scss-lint-0.17.1
Parsing documentation for colorize-0.5.8
Installing ri documentation for colorize-0.5.8
Parsing documentation for sass-3.3.0.rc.1
Installing ri documentation for sass-3.3.0.rc.1
Parsing documentation for scss-lint-0.17.1
Installing ri documentation for scss-lint-0.17.1

现在我得到了(当我尝试运行指南针命令;指南针创建;指南针监视等等)

/Library/Ruby/Site/2.0.0/rubygems/core_ext/kernel_require.rb:55:in `require': cannot load such file -- sass/script/node (LoadError)
    from /Library/Ruby/Site/2.0.0/rubygems/core_ext/kernel_require.rb:55:in `require'
    from /Library/Ruby/Gems/2.0.0/gems/compass-0.12.2/lib/compass/sass_extensions/monkey_patches/browser_support.rb:1:in `<top (required)>'
    from /Library/Ruby/Site/2.0.0/rubygems/core_ext/kernel_require.rb:55:in `require'
    from /Library/Ruby/Site/2.0.0/rubygems/core_ext/kernel_require.rb:55:in `require'
    from /Library/Ruby/Gems/2.0.0/gems/compass-0.12.2/lib/compass/sass_extensions/monkey_patches.rb:2:in `block in <top (required)>'
    from /Library/Ruby/Gems/2.0.0/gems/compass-0.12.2/lib/compass/sass_extensions/monkey_patches.rb:1:in `each'
    from /Library/Ruby/Gems/2.0.0/gems/compass-0.12.2/lib/compass/sass_extensions/monkey_patches.rb:1:in `<top (required)>'
    from /Library/Ruby/Site/2.0.0/rubygems/core_ext/kernel_require.rb:55:in `require'
    from /Library/Ruby/Site/2.0.0/rubygems/core_ext/kernel_require.rb:55:in `require'
    from /Library/Ruby/Gems/2.0.0/gems/compass-0.12.2/lib/compass/sass_extensions.rb:9:in `<top (required)>'
    from /Library/Ruby/Site/2.0.0/rubygems/core_ext/kernel_require.rb:55:in `require'
    from /Library/Ruby/Site/2.0.0/rubygems/core_ext/kernel_require.rb:55:in `require'
    from /Library/Ruby/Gems/2.0.0/gems/compass-0.12.2/lib/compass.rb:5:in `block in <top (required)>'
    from /Library/Ruby/Gems/2.0.0/gems/compass-0.12.2/lib/compass.rb:4:in `each'
    from /Library/Ruby/Gems/2.0.0/gems/compass-0.12.2/lib/compass.rb:4:in `<top (required)>'
    from /Library/Ruby/Site/2.0.0/rubygems/core_ext/kernel_require.rb:55:in `require'
    from /Library/Ruby/Site/2.0.0/rubygems/core_ext/kernel_require.rb:55:in `require'
    from /Library/Ruby/Gems/2.0.0/gems/compass-0.12.2/bin/compass:20:in `block in <top (required)>'
    from /Library/Ruby/Gems/2.0.0/gems/compass-0.12.2/bin/compass:8:in `fallback_load_path'
    from /Library/Ruby/Gems/2.0.0/gems/compass-0.12.2/bin/compass:19:in `<top (required)>'
    from /usr/bin/compass:23:in `load'
    from /usr/bin/compass:23:in `<main>'

我删除了scss-lint sudo gem uninstall scss-lint

但没有改变

有人能帮助我吗?

我发现了一些类似的问题,但大多数都与rvm(我没有安装)有关。

我的宝石是:

$ gem list

*** LOCAL GEMS ***

actionmailer (4.0.2)
actionpack (4.0.2)
activemodel (4.0.2)
activerecord (4.0.2)
activerecord-deprecated_finders (1.0.3)
activesupport (4.0.2)
arel (4.0.1)
atomic (1.1.14)
builder (3.1.4)
bundler (1.3.5)
CFPropertyList (2.2.0)
chunky_png (1.2.9)
colorize (0.5.8)
compass (0.12.2)
diff-lcs (1.2.5)
erubis (2.7.0)
ffi (1.9.3)
fssm (0.2.10)
haml (4.0.4)
hike (1.2.3)
i18n (0.6.9)
libxml-ruby (2.6.0)
listen (1.1.6)
mail (2.5.4)
mime-types (1.25.1)
minitest (4.7.5)
modular-scale (1.0.6)
multi_json (1.8.2)
nokogiri (1.5.6)
observr (1.0.5)
polyglot (0.3.3)
rack (1.5.2)
rack-test (0.6.2)
rails (4.0.2)
railties (4.0.2)
rake (10.1.1)
rb-fsevent (0.9.4)
rb-inotify (0.9.3)
rb-kqueue (0.2.0)
rspec (2.14.1)
rspec-core (2.14.7)
rspec-expectations (2.14.4)
rspec-mocks (2.14.4)
rspec-rails (2.14.0)
rubygems-update (2.2.1)
sass (3.3.0.rc.2, 3.3.0.rc.1)
sassy-math (1.5)
scss-lint (0.17.1)
sprockets (2.10.1)
sprockets-rails (2.0.1)
sqlite3 (1.3.7)
styleguide (0.1.0)
terminal-notifier (1.5.1)
thor (0.18.1)
thread_safe (0.1.3)
tilt (1.4.1)
treetop (1.4.15)
tzinfo (0.3.38)
watchr (0.7)

1 个答案:

答案 0 :(得分:0)

看起来您需要指定sass gem的早期版本才能让它再次运行:

  

假设您通过scss-lint安装了gem install scss-lint而没有安装Gemfile   在你的sass中,你应该能够解决问题   将Gemfile中的3.2.12版本固定到scss-lint以便捆绑   不会自动尝试加载最新版本。

从{{1}}问题列表中获取答案:https://github.com/brigade/scss-lint/issues/54