2013-03-13 119 views
0

耙我安裝紅寶石的一切都在軌道上我的Linux system..and然後當我鍵入命令「約耙」下面是error..plz幫助錯誤,同時運行有關命令

rake aborted! 
    Could not find a JavaScript runtime. See https://github.com/sstephenson/execjs for a     list of available runtimes. 
    /home/imobigeeks1/work/demo/jbuilder/ruby/1.8/gems/execjs-1.4.0/lib/execjs/runtimes.rb:51:in `autodetect' 
    /home/imobigeeks1/work/demo/jbuilder/ruby/1.8/gems/execjs-1.4.0/lib/execjs.rb:5 
    /home/imobigeeks1/work/demo/jbuilder/ruby/1.8/gems/coffee-script-2.2.0/lib/coffee_script.rb:1:in `require' 
    /home/imobigeeks1/work/demo/jbuilder/ruby/1.8/gems/coffee-script-2.2.0/lib/coffee_script.rb:1 
    /home/imobigeeks1/work/demo/jbuilder/ruby/1.8/gems/coffee-script-2.2.0/lib/coffee-script.rb:1:in `require' 
    /home/imobigeeks1/work/demo/jbuilder/ruby/1.8/gems/coffee-script-2.2.0/lib/coffee- script.rb:1 
    /home/imobigeeks1/work/demo/jbuilder/ruby/1.8/gems/coffee-rails-3.2.2/lib/coffee- rails.rb:1:in `require' 
    /home/imobigeeks1/work/demo/jbuilder/ruby/1.8/gems/coffee-rails-3.2.2/lib/coffee- rails.rb:1 
    /home/imobigeeks1/work/demo/config/application.rb:7 
    /home/imobigeeks1/work/demo/Rakefile:5 
    (See full trace by running task with --trace) 

而且我也安裝了javascript使用gem install execjs命令仍然顯示相同的問題

+0

請格式化您的文章,並在此提供相關的代碼,不涉及庫 – Blizzer 2013-03-13 11:41:42

+0

你安裝包\ – 2013-03-13 11:43:57

+0

耙中止!找不到JavaScript運行時。 – user2164254 2013-03-13 11:45:52

回答

0

gem 'therubyracer'放在你的gemfile中,然後從命令行執行bundle install

這種寶石換

調用JavaScript代碼和操作來自紅寶石JavaScript對象。致電 Ruby代碼並使用JavaScript處理Ruby對象。

來源 - ?http://rubydoc.info/gems/therubyracer/0.11.4/frames

+0

是的,它得到了working..thanx :) – user2164254 2013-03-13 11:57:16