Tag: therubyracer

WINDOWS上的Rails:安装therubyracer和libv8 – 在MAC上设计的网站上工作

我有一个开发的网站是关于MAC的RoR v 4.2.4需要一些调整,我试图在我的Windows 10上运行(因为我没有MAC)。我没有成功使用rails安装程序和rails 5.0。 使用ruby 2.2.6安装RoR 4.2.4后出了很多痛苦我使用bundle check , bundle install和gem install xyz -v 0.0…设法安装了几乎所有缺失的gem。 但现在我真的陷入了最后的2: therubyracer和libv8 我尝试了什么: 安装libv8与gem install libv8 -v 3.16.14.11 — –with-system-v8以及此处提到的therubyracer-for-windows。 修改gemfile.lock以消除依赖关系,如: group :production do gem ‘therubyracer’ end 并尝试bundle install –without production 。 但是在启动服务器时出现错误。 目前bundle check说,therubyracer v 0.12.2是最后遗失的gem。 libv8与–with-system-v8一起安装。 gem list说libv8(3.16.14.11)和therubyracer(0.11.0b)已安装,但系统似乎没有找到therubyracer,因为: therubyracer -v不起作用。 另外bundle install给我以下错误: C:/Ruby22-x64/bin/ruby.exe -r ./siteconf20170122-10664-jwvn48.rb extconf.rb –with-v8-dir=/usr/local/opt/v8-315 […]

therubyracer安装错误。 我尝试了所有其他SO解决方案但仍然没有运气

我认为这是在Rails中安装therubyracer gem的常见问题。 它是twitter-bootstrap-rails gem的依赖项。 我尝试过这样的解决方案: `gem install therubyracer`在Mac OS X Lion上失败了 这是我的gem文件的相关部分: group :assets do gem ‘sass-rails’, ‘~> 3.2.3’ gem ‘coffee-rails’, ‘~> 3.2.1’ # See https://github.com/sstephenson/execjs#readme for more supported runtimes gem ‘therubyracer’, :platforms => :ruby gem ‘uglifier’, ‘>= 1.0.3’ gem ‘twitter-bootstrap-rails’ end 这是运行bundle install时出现的错误: Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension. /Users/lionel_lei/.rvm/rubies/ruby-1.9.3-p194/bin/ruby extconf.rb checking […]

什么是therubyracer或libv8 for rails应用程序?

我正在研究一个项目,经常遇到therubyracer和libv8的问题,所以我决定删除它们。 它似乎是唯一使用它们作为依赖的东西是较少的轨道,我想要删除无论如何。 我的主要问题是它们是什么,我是否需要它们在普通应用程序中,如果是这样,为什么?

我无法在Arch Linux x64中安装therubyracer

当我尝试安装therubyracer时,我收到以下错误: Installing therubyracer (0.11.0) with native extensions Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension. /home/carlos/.rbenv/versions/1.9.3-p327/bin/ruby extconf.rb checking for main() in -lpthread… yes checking for v8.h… yes creating Makefile make compiling script.cc compiling v8.cc compiling backref.cc compiling value.cc compiling accessor.cc compiling trycatch.cc compiling primitive.cc compiling external.cc compiling date.cc compiling exception.cc compiling init.cc compiling template.cc compiling […]

在OS X 10.10上,gem install therubyracer -v 0.11.4失败

按照这里的步骤“gem install therubyracer -v’0.10’”在osx mavericks上没有安装 ,我能够得到therubyracer -v 0.10.2和0.12.0来安装好,但不是0.11.4。 gem install therubyracer -v 0.11.4 返回: Building native extensions. This could take a while… ERROR: Error installing therubyracer: ERROR: Failed to build gem native extension. /Users/thooper/.rbenv/versions/2.1.2/bin/ruby -r ./siteconf20150102-7132-9ct9a4.rb extconf.rb creating Makefile Compiling v8 for x64 Using python 2.7.9 Configured with: –prefix=/Applications/Xcode.app/Contents/Developer/usr –with-gxx-include-dir=/usr/include/c++/4.2.1 Unable to find a compiler […]

TypeError:Object不支持此属性或方法

我已创建rails应用程序,我在其中创建了一个数据库(空)。 当我尝试查看我的产品页面时,我在http:// localhost:3000 / products页面上收到以下错误。 在迁移数据库之前,应用程序确实起作用。 我正在使用therubyracer,我在Windows 7上。 ExecJS::ProgramError in Products#index Showing C:/RailsInstaller/DevKit/home/JP/nameofapp/app/views/layouts/application.html.erb where line #16 raised: TypeError: Object doesn’t support this property or method (in C:/RailsInstaller/Ruby2.1.0/lib/ruby/gems/2.1.0/gems/turbolinks-2.5.3/lib/assets/javascripts/turbolinks.js.coffee) Extracted source (around line #16): 13 14 15 true %> 16 true %> 17 18 19 Rails.root: C:/RailsInstaller/DevKit/home/JP/nameofapp 这是我在Rails服务器上得到的: Started GET “/products” for 127.0.0.1 at 2015-04-23 22:28:06 -0400 […]

使用therubyracer在Windows机器上安装ruby gem less-rails

我有一段时间试图在我的windows7机器上安装less-rails gem。 我已经设法使用这个二进制文件安装所需的therubyracer.gem: https : //github.com/stereobooster/therubyracer/downloads 我还下载了v8.dll并放入我的ruby / bin目录。 到目前为止一切运行良好,捆绑安装正在运行,服务器启动没有任何问题。 但是,只要我使用较少的文件请求页面,我就会收到以下错误消息 未定义的方法`in_javascript?’ for#“ 我的css.file是空的 /* *= require ‘custom_less/custom’ *= require ‘jquery-ui-1.8.24.custom’ */ custom.css.less看起来像这样 @import “twitter/bootstrap/reset”; @import “twitter/bootstrap/variables”; @import “custom_less/variables”; // Your own variable overrides. @import “twitter/bootstrap/mixins”; @import “custom_less/mixins”; // Your own mixin. @import “twitter/bootstrap/scaffolding”; @import “twitter/bootstrap/grid”; @import “twitter/bootstrap/layouts”; //import of further bootstrap components //but nothing […]