gem

Error on running Jekyll with jekyll-multiple-languages-plugin

☆樱花仙子☆ 提交于 2019-12-12 02:46:08
问题 I am trying to run Jekyll server on Windows using jekyll-multiple-languages-plugin but I keep getting this error message: C:/Ruby200/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:55:in `require': cannot load such file -- jekyll-multiple-languages-plugin (LoadError) from C:/Ruby200/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:55:in `require' from C:/Ruby200/lib/ruby/gems/2.0.0/gems/jekyll-2.0.3/lib/jekyll/plugin_manager.rb:28:in `block in require_gems' from C:/Ruby200/lib/ruby/gems

Bundler gem compatibility issues when deploying to heroku.

▼魔方 西西 提交于 2019-12-12 02:45:21
问题 I receive the following error message is when deploying to heroku: Bundler could not find compatible version for gem "railties": In Gemfile: rails (= 4.0.0) ruby depends on railties (= 4.0.0) ruby coffee-rails (= 4.0.0) ruby depends on railties (4.0.1.rc1) Failed to install gems via Bundler Gemfile source 'https://rubygems.org' ruby '1.9.3' gem 'rails', '4.0.0' gem 'bcrypt-ruby', '3.0.1' gem 'faker', '1.1.2' gem 'will_paginate', '3.0.4' gem 'will_paginate-bootstrap' group :development, :test

Ruby on Rails: Can't install JSON gem

余生颓废 提交于 2019-12-12 02:44:11
问题 When I try to create a new Rails application rails new app , the process stops when trying to install the JSON gem. So, I tried to install it alone, using: gem install json but I get the following error message: Building native extensions. This could take a while... ERROR: Error installing json: ERROR: Failed to build gem native extension. /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby extconf.rb creating Makefile make xcrun cc -I. -I/System/Library/Frameworks/Ruby

Could not find a valid gem 'rails' (>= 0) in any repository

一曲冷凌霜 提交于 2019-12-12 02:38:47
问题 I'm on a fresh mac and just installed ruby 1.9.3 using rvm. Now I'm trying to install rails and getting the error on the title of this post. I'll post below all info I have from the command line to see if anyone can help me out here!! Leonardos-MacBook-Air:~ leo$ gem install rails WARNING: Error fetching data: SocketError: getaddrinfo: nodename nor servname provided, or not known (http://rubygems.org/latest_specs.4.8.gz) ERROR: Could not find a valid gem 'rails' (>= 0) in any repository ERROR

Get the hashtag using twitter gem

假如想象 提交于 2019-12-12 02:08:10
问题 I am using twitter gem to stream tweets in ruby. My code is client.filter(:track => topics.join(",")) do |object| if(object.is_a?(Twitter::Entities)) puts object.text if object.is_a?(Twitter::Tweet) puts object.created_at puts object.hashtags.to_s puts object.user.name end end I need to fetch the hashtags in the tweet, if i use the above code I am getting the output as [#<Twitter::Entity::Hashtag:0x007ff23a06d4c8 @attrs={:text=>"coffee", :indices=>[20, 27]}>, #<Twitter::Entity::Hashtag

Sending Notification to App using Rpush Gem Ruby on Rails

扶醉桌前 提交于 2019-12-12 02:04:46
问题 Im trying to implement Push notification in my app using Rpush Gem. This is so far i have tried. if @push_notification.present? else app = Rpush::Apns::App.new app.name = "ios_app" app.certificate = File.read("config/apns-dev.pem") app.environment = "development" # APNs environment. app.password = "" app.connections = 1 app.save! end n = Rpush::Apns::Notification.new n.app = Rpush::Apns::App.find_by_name("ios_app") n.device_token = session[:push_notification_token] n.alert = "hi im alert!" n

A problem with the “require” keyword not finding the file to load

半世苍凉 提交于 2019-12-12 01:04:45
问题 I have a problem with the "require" keyword in ruby, I just downloaded a gem using: gem install thegem And when I tried running an example I received the following error: <internal:lib/rubygems/custom_require>:29:in `require': no such file to load -- ./thegem/some/path (LoadError) In the code where the problem is: needs_to_load = a_class require "gem/some/path/#{needs_to_load}" I'm a Ruby noob learning my way around and am not sure what this is, a google search didn't help but revealed that

Installing gems with extensions always fails

◇◆丶佛笑我妖孽 提交于 2019-12-12 00:04:13
问题 I just setup an Ubuntu 13.04 server, and installed RVM 1.21.11, Ruby 1.9.3-p448, and Rubygems 2.0.5 . Many gems, such as mongo , awesome_print , aws-s3 , and json , installed successfully. However, gems that compile an extension fail. I've tried to install nokogiri , mongo_ext , and bson_ext . They all fail in the same way, as shown below. Any idea how to fix this? [nick@mongo01 ~] gem install mongo_ext -u -V --backtrace HEAD http://rubygems.org/latest_specs.4.8.gz 302 Moved Temporarily HEAD

Trouble on re-installing Ruby from scratch

六眼飞鱼酱① 提交于 2019-12-11 23:33:27
问题 I am using rvm (Ruby Version Manager) and I deleted some gems by running the gem update --system command. I had some serious problem so I decided to reinstall rvm and ruby 1.9.2 on my local machine (MacOS Snow Leopard 10.6.7). Now, if I run the rails s command I get the following $ rails s /Library/Ruby/Site/1.8/rubygems.rb:779:in `report_activate_error': Could not find RubyGem rails (>= 0) (Gem::LoadError) from /Library/Ruby/Site/1.8/rubygems.rb:214:in `activate' from /Library/Ruby/Site/1.8

ruby - Error with installing bluecloth-2.2.0 gem in Win 7 , ruby 1.9.3

…衆ロ難τιáo~ 提交于 2019-12-11 23:12:04
问题 Was following steps described in https://stackoverflow.com/a/13544086/3206440 for resolving error with bluecloth-2.2.0 gem installation in windows 7. Encountered an error in step 4 given in the above link - any ideas? Console output below. C:\RailsInstaller\Ruby1.9.3\lib\ruby\gems\1.9.1\gems\bluecloth-2.2.0>rake gem C:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/bluecloth-2.2.0/Rakefile:24 : Use RbConfig instead of obsolete and deprecated Config. Defaulting gemspec to MIT license. Call