rubygems

RoR Passenger webserver "Extra File" errors on gem check --alien

I just installed the Phusion Passenger webserver via gem install. I then did a gem check --alien and got this error message: fastthread-1.0.7 has 3 problems .require_paths: Extra file ext/fastthread/Makefile: Extra file lib/fastthread.rb: Extra file passenger-2.2.15 has 5 problems .require_paths: Extra file ex...

Is it possible to show ruby gem updates without actually updating?

I have checked the docs, but I didn't find a way to check for gems with updates available. I was wondering if anyone knew how to do this? ...

How do you access sessions and cookies from within a Rails gem or lib?

Im trying to create what will eventually be a rails gem (right now I have the files within the /lib directory) and I need to be able to read/write to and from cookies and sessions. My methods will be called from within either the controller or views, so access to the cookies and sessions SHOULD be possible from within my gem but I cant ...

How do I get a Ruby CGI program that requires a gem to run properly?

Hello! I have configured my Apache installation to run Ruby CGI scripts. I am now trying to run a simple Ruby CGI script that requires a gem. When I run this script from the command line, it outputs correctly. But when I call it as an Apache CGI script, it generates an Apache Internal Server Error. The script looks like this: #!/Ruby/...

Rails image uploader and EXIF data reader?

Any decent paperclip-like Ruby gems that also read EXIF data? It would be a huge bonus if the gem was Windows-friendly. ...

Does this Ruby on Rails code use a Gem?

I've just inherited a website built with Ruby on Rails. I have never used the language before. One thing I wanted to know is about Gems - my host only supports a few. I figure a Gem is like a library with PHP - for example, the mysql library is compiled with most PHP packages. So I was wondering, does the following short code sample re...

Ruby gems won't load even though installed

I know there's similar questions on SO, but none of them solve my problem... The gist of it is that I can't get gems to load on a clean Ruby 1.9.1 install on Ubuntu 10.04: :~/$ irb irb(main):001:0> require 'rubygems' => false irb(main):002:0> require 'cassandra' LoadError: no such file to load -- cassandra from (irb):1:in 'require'...

undefined method get_uptime for Facter::Util::Uptime:Module (NoMethodError)

I'm trying to setup a puppet node, but rubygems doesn't seem to behave. If I run facter on the cli via it's own binary (/usr/lib/ruby/gems/1.8/gems/facter-1.5.8/bin/facter), it works fine, but if I run it through the binary installed by rubygems (/usr/bin/facter), it throws: /usr/lib/ruby/1.8/facter/uptime.rb:11: undefined method `get_...

Dumping all key/value pairs in a Redis db

I'm using an ORM called Ohm in Ruby that works on top of Redis and am curious to find out how the data is actually stored. I was wondering if there is way to list all the keys/values in a Redis db. Any lead will go a long way in helping me out (I'm basically stuck atm). Thanks in advance! Update: A note for others trying this out using...

How to enable 'Click to toggle source' button' in Ruby RDoc.

When using the Darkfish RDoc generator to generate RDoc documentation, next to methods there is a Click to toggle source button next to each method. It isn't working for me when I generate my documentation, so how do you get that feature to work, do you have to add a keyword into your RDoc source or something? ...

How do you create a rails migration generator in a ruby gem?

Im creating a simple Rails 2.3.8 gem and need a migration file inside it. I following this structure: / /generators /generators/conductor_migration /generators/conductor_migration/conductor_migration_generator.rb /generators/conductor_migration/templates /generators/conductor_migration/templates/conductor_migration.rb but when I inst...

daemon spawn : gem_original_require : no such file to load --daemon-spawn (Load Error)

I am trying to run daemon process using daemon-spawn gem. Here is the code for delayed_delta daemon process #file - script/dj #!/usr/bin/env ruby # -*- ruby -*- require 'rubygems' require 'daemon-spawn' RAILS_ROOT = File.expand_path(File.join(File.dirname(__FILE__), '..')) class DelayedJobWorker ENV['MIN_PRIORITY'], :max_prior...

Dragonfly question

Hello! I tried switching from gem rails 3.0.0.rc to rails 3.0.0 in my Gemfile recently and when doing so I got a problem with Dragonfly when starting the server. The error message says: /Library/Ruby/Gems/1.8/gems/aws-s3-0.6.2/lib/aws/s3/extensions.rb:206:in `const_missing': uninitialized constant Dragonfly::Config::HerokuRailsImages (...

Cannot Install Ruby Gems 1.3.7 on Mac OSX 10.6.4

I am following the instructions at http://hivelogic.com/articles/compiling-ruby-rubygems-and-rails-on-snow-leopard to install ruby 1.9.2 and rubygems 1.3.7 Everything goes smoothly until I get to the "Compile and Install RubyGems" part and enter the command line: sudo /usr/local/bin/ruby setup.rb This continually returns the followin...

How to move your rake tasks to the rails lib dir from in a gem generator?

Im creating a custom gem and have some rake files that need to be installed into the users /lib/tasks directory to work. I want create a generator that will move / create my rake tasks in the tasks directory so they can use them. Does anyone have any idea how do to this in a custom gem? ...

Why does RubyGems FasterCSV process [[1,3,5], [2,4,6]].to_csv as "135,246\n"

the following code: [1,3,5].to_csv => "1,3,5\n" # this is good [[1,3,5], [2,4,6]].to_csv => "135,246\n" # why doesn't it just do it for array of array? but require this instead: data = [[1,3,5], [2,4,6]] csv_string = FasterCSV.generate do |csv| data.each {|a| csv << a} end => "1,3,5\n2,4,6\n" or shorter: data =...

Scrubyt "next_page" not working with relative links?

Hello all. I'm trying to scrape the the Yellow Pages website. Specifically, this link http://www.yellowpages.com/santa-barbara-ca/restaurants. My code works perfectly except for one small problem. Because the "Next" link to go to the next page of restaurants is a relative link, Scrubyt's "next_page" function doesn't work...apparently...

What's the best ruby gem for image uploads?

Hey everyone, I've been dealing with Rails 3, Paperclip and Windows 7 for a few nights now and don't feel like I'm actually getting anywhere. I've hit config issue after config issue and it's a bit of a nightmare. Can anyone recommend any other gems that will accomplish the same thing? Thanks, Brandon ...

How can I use "nu install ..." to install nhibernate 3 alpha?

Hi all, I've started using nu and I'm really starting to like the way it managed packages for .net libraries. On this page: http://nu.wikispot.org/Current_Packages it says that you can install the nhibernate alpha version with nu, however I can't for the life of me figure out how. Can anyone help me with the command I would need? Tha...

rails console - display active record results in a table

Is there a way to display Active Record results in table format in the script/console environment? ...