日期:2014-05-16 浏览次数:20409 次
1.命令行下进入应用程序目录cd G:\BaiduYun\Project\RubyonRails\rails_projects\blog
2.执行bundle show execjs显示execjs目录。(如果没有安装execjs,则运行gem install execjs后再执行此步骤)
3.进入execjs目录下的lib->execjs
4.将runtimes.rb备份,并修改里面的内容。(41-46行)
改之前:
JScript = ExternalRuntime.new( :name => "JScript", :command => "cscript //E:jscript //Nologo //U", :runner_path => ExecJS.root + "/support/jscript_runner.js", :encoding => 'UTF-16LE' # CScript with //U returns UTF-16LE )改之后:
JScript = ExternalRuntime.new( :name => "JScript", :command => "cscript //E:jscript //Nologo", :runner_path => ExecJS.root + "/support/jscript_runner.js", :encoding => 'UTF-8' )