【问题标题】:Problems running Compass Watch on a Drupal install with Omega 4使用 Omega 4 在 Drupal 安装上运行 Compass Watch 时出现问题
【发布时间】:2014-09-01 02:37:59
【问题描述】:

我一直在调试这个安装。我知道命令 compass watch 可以与其他 drupal 安装一起使用,但这是我第一次将它与 Omega 主题一起使用。我遇到了这个错误。

C:\webdev\sites\all\themes\cee>指南针手表 指南针正在观察变化。按 Ctrl-C 停止。 ArgumentError on line ["500"] of C: different prefix: "C:/" and "C:\webdev/sites/all/themes/cee/sass" 使用 --trace 运行以查看完整的回溯

我在网上找到的所有解决方案都适用于将 ruby​​ 安装在另一个分区上的人,但我的解决方案是相同的。问题似乎是正斜杠而不是反斜杠,但我不知道如何纠正这个问题。我在与 config.rb 相同的目录中运行 compass watch。任何帮助将不胜感激。

这里使用--trace 运行命令。 C:\webdev\sites\all\themes\cee>compass watc h --trace

Compass 正在关注变化。按 Ctrl-C 停止。 ArgumentError on line ["500"] of C: different prefix: "C:/" and "C:\webdev/sites/all/themes/cee/sass" C:/Ruby200/lib/ruby/gems/2.0.0/gems/sass-globbing-1.1.1/lib/sass/globbing/impo rter.rb:60:in mtime' C:/Ruby200/lib/ruby/gems/2.0.0/gems/sass-3.3.9/lib/sass/plugin/staleness_check er.rb:134:inmtime' C:/Ruby200/lib/ruby/gems/2.0.0/gems/sass-3.3.9/lib/sass/plugin/staleness_check er.rb:163:in block in dependency_updated?' C:/Ruby200/lib/ruby/gems/2.0.0/gems/sass-3.3.9/lib/sass/plugin/staleness_check er.rb:125:ineach' C:/Ruby200/lib/ruby/gems/2.0.0/gems/sass-3.3.9/lib/sass/plugin/staleness_check er.rb:125:in any?' C:/Ruby200/lib/ruby/gems/2.0.0/gems/sass-3.3.9/lib/sass/plugin/staleness_check er.rb:125:independencies_stale? C:/Ruby200/lib/ruby/gems/2.0.0/gems/sass-3.3.9/lib/sass/plugin/staleness_check er.rb:166:in block in dependency_updated?' C:/Ruby200/lib/ruby/gems/2.0.0/gems/sass-3.3.9/lib/sass/plugin/staleness_check er.rb:125:ineach' C:/Ruby200/lib/ruby/gems/2.0.0/gems/sass-3.3.9/lib/sass/plugin/staleness_check er.rb:125:in any?' C:/Ruby200/lib/ruby/gems/2.0.0/gems/sass-3.3.9/lib/sass/plugin/staleness_check er.rb:125:independencies_stale? C:/Ruby200/lib/ruby/gems/2.0.0/gems/sass-3.3.9/lib/sass/plugin/staleness_check er.rb:166:in block in dependency_updated?' C:/Ruby200/lib/ruby/gems/2.0.0/gems/sass-3.3.9/lib/sass/plugin/staleness_check er.rb:81:incall' C:/Ruby200/lib/ruby/gems/2.0.0/gems/sass-3.3.9/lib/sass/plugin/staleness_check er.rb:81:in stylesheet_modified_since?' C:/Ruby200/lib/ruby/gems/2.0.0/gems/sass-3.3.9/lib/sass/plugin/staleness_check er.rb:69:instylesheet_needs_update?' C:/Ruby200/lib/ruby/gems/2.0.0/gems/compass-1.0.0.alpha.20/lib/compass/compile r.rb:85:in needs_update?' C:/Ruby200/lib/ruby/gems/2.0.0/gems/compass-1.0.0.alpha.20/lib/compass/compile r.rb:79:inblock in out_of_date?' C:/Ruby200/lib/ruby/gems/2.0.0/gems/compass-1.0.0.alpha.20/lib/compass/compile r.rb:78:in each' C:/Ruby200/lib/ruby/gems/2.0.0/gems/compass-1.0.0.alpha.20/lib/compass/compile r.rb:78:inout_of_date? C:/Ruby200/lib/ruby/gems/2.0.0/gems/compass-1.0.0.alpha.20/lib/compass/watcher /compiler.rb:20:in compile' C:/Ruby200/lib/ruby/gems/2.0.0/gems/compass-1.0.0.alpha.20/lib/compass/command s/watch_project.rb:47:inperform' C:/Ruby200/lib/ruby/gems/2.0.0/gems/compass-1.0.0.alpha.20/lib/compass/command s/base.rb:18:in execute' C:/Ruby200/lib/ruby/gems/2.0.0/gems/compass-1.0.0.alpha.20/lib/compass/command s/project_base.rb:19:inexecute' C:/Ruby200/lib/ruby/gems/2.0.0/gems/compass-1.0.0.alpha.20/lib/compass/exec/su b_command_ui.rb:43:in perform!' C:/Ruby200/lib/ruby/gems/2.0.0/gems/compass-1.0.0.alpha.20/lib/compass/exec/su b_command_ui.rb:15:inrun! C:/Ruby200/lib/ruby/gems/2.0.0/gems/compass-1.0.0.alpha.20/bin/compass:30:in block in <top (required)>' C:/Ruby200/lib/ruby/gems/2.0.0/gems/compass-1.0.0.alpha.20/bin/compass:44:in 称呼' C:/Ruby200/lib/ruby/gems/2.0.0/gems/compass-1.0.0.alpha.20/bin/compass:44:in <top (required)>' C:/Ruby200/bin/compass:23:inload' C:/Ruby200/bin/compass:23:in `'

此外,在我认为相关的调试过程中,我也多次收到此错误。

WDM::c 的 [73] 行出错:无法获取传递目录的绝对路径:''! 使用 --trace 运行以查看完整的回溯

【问题讨论】:

  • 虽然我从未解决过这个确切的问题,但在卸载所有内容并重新开始后,我设法让它工作。我认为部分问题是我陷入了依赖地狱。 Bundle 帮助了我,我最终得到了 bundle exec compass compile 的结果,并用所有缺失的依赖项编辑了我的 gem 文件。通过 bundle 更新,最终允许 compass 通过运行 bundle exec compass watch 正常工作。

标签: ruby ruby-on-rails-3 drupal gem rubygems


【解决方案1】:

我在将 Ruby 更新到 2.0 版本时遇到了同样的问题,但在旧版本的 Ruby (1.9.3) 上没有出现此问题。

我删除了新版本的 Ruby 并恢复了旧版本(删除了 2.0 版的 DevKit 并安装了 Ruby 1.9.3 版的 DevKit),这一切都像一个魅力。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2021-02-20
    • 1970-01-01
    • 2018-12-24
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多