新手问题 有人用过 grit 么

Tag · November 24, 2012 · Last by Tag replied at November 26, 2012 · 2463 hits

我在安装好 gem install grit 后

在 Gemfile 中加载 gem "grit" 报 cannot load such file -- posix_spawn_ext 错误,

*** LOCAL GEMS ***

actionmailer (3.2.9, 3.2.5) actionpack (3.2.9, 3.2.5) activemodel (3.2.9, 3.2.5) activerecord (3.2.9, 3.2.5) activeresource (3.2.9, 3.2.5) activesupport (3.2.9, 3.2.5) arel (3.0.2) bigdecimal (1.1.0) builder (3.0.4, 3.0.0) bundler (1.2.2, 1.1.4) coffee-rails (3.2.2) coffee-script (2.2.0) coffee-script-source (1.4.0) daemon_controller (1.1.0) diff-lcs (1.1.3) erubis (2.7.0) execjs (1.4.0) fastthread (1.0.7) git (1.2.5) grit (2.5.0) hike (1.2.1) i18n (0.6.1, 0.6.0) io-console (0.3) journey (1.0.4, 1.0.3) jquery-rails (2.1.3) json (1.7.5, 1.6.5) libv8 (3.3.10.4 x86-linux) mail (2.4.4) mime-types (1.19, 1.18) minitest (4.3.0) multi_json (1.3.7, 1.3.6) mysql (2.9.0) passenger (3.0.18) polyglot (0.3.3) posix (0.0.5) posix-spawn (0.3.6) rack (1.4.1) rack-cache (1.2) rack-ssl (1.3.2) rack-test (0.6.2, 0.6.1) rails (3.2.9) railties (3.2.9, 3.2.5) rake (10.0.1, 0.9.2.2) rdoc (3.12) sass (3.2.3) sass-rails (3.2.5) sprockets (2.2.1, 2.1.3) therubyracer (0.10.1) thor (0.16.0, 0.15.2) tilt (1.3.3) treetop (1.4.12, 1.4.10) tzinfo (0.3.35, 0.3.33) uglifier (1.3.0) unit (0.4.1)

以上是安装了的包

一直每找到原因 网上也没搜到。。

在 irb 下却能加载 require 'grit' => true. rails c 下面提示 cannot such file grit

https://github.com/mojombo/grit/issues/110#issuecomment-8209213

楼主用 jruby 吗?我之前用是好的,没碰到过这个错误

#1 楼 @vkill 不是,ruby... 不用 jruby..

环境系统 fedora 17

You need to Sign in before reply, if you don't have an account, please Sign up first.