首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 网络技术 > 网络基础 >

实施rails server 出现in `autodetect': Could not find a JavaScript runtime

2013-08-01 
执行rails server 出现in `autodetect: Could not find a JavaScript runtime.执行rails serverin `autod

执行rails server 出现in `autodetect': Could not find a JavaScript runtime.

执行rails server

in `autodetect': Could not find a JavaScript runtime. See https://github.com/sstephenson/execjs for a list of available runtimes. (ExecJS::RuntimeUnavailable)

解决方案1:在GemFile(文件的位置在项目的首页中) 文件的末尾加上gem 'execjs'?

gem 'therubyracer'

之后执行bundle install

?

?

解决方法2:

安装nodejs

lijg@lijg-desktop:~/workruby/helloapp$ sudo apt-cache search nodejs
[sudo] password for lijg:
coffeescript - interpreter and compiler for the CoffeeScript language
nodejs - Node.js event-based server-side javascript engine
nodejs-dbg - Node.js event-based server-side javascript engine (debug)
nodejs-dev - Development files for Node.js

热点排行