rubygems

Installing MySQL and mysql gem on Snow Leopard

It´s really a hard job figuring out how to get MySQL and mysql gem up and running on Snow Leopard 10.6.2. I followed the instructions of various posts but was not successful yet: I build MySQL Version 5.1.39 from source and it installed successfully. When trying to login using (mysql -u root -p) mysql returned the following error: ERR...

convert partial to string from active record

HI friends, I have a situation where i have to convert a partial into string from Active-Record. Here is the code: Facebooker::Session.create(Facebooker.api_key, Facebooker.secret_key).send_email( facebook_user_id, "MAIL_SUBJECT", (:partial=>"some/partial") ) This is being called from a model. T...

undefined local variable or method 'within' for User:class

Hi there! I am working with a book to teach myself Ruby-on-Rails. Ruby version is 1.2.3 and rubygems V 1.3.5. I start the console by ruby script/console and enter: user = User.new(:screen_name => "example", ?> :email => "exampleATexample.com", ?> :password => "example") but instead of adding the data to the DB, I get the following: ...

Local installation of ruby / rubygems with no root access

Hi, I have a machine at work from wich I'd like to run a script that gathers some information about other machines. I want to do it in Ruby, since it's what I know best, but I've ran into some problems, all apparently due to the same reason: I don't have root access in this machine. So what I did was: Download ruby source, configure (w...

History of rails script/generate commands

Is there a plugin/gem to log/record the history of rails script/generate commands? ...

Problem installing mysql gem on Snow Leopard: uninitialized constant MysqlCompat::MysqlRes

Hi All I've got a problem trying to install the Ruby mysql gem driver. I recently upgraded to Snow Leopard and did the Hivelogic manual install of MySQL. This all seems to work fine as I can access mysql from the command line and make changes to the database. My problem is that if I now use rake db:migrate I get: rake aborted! uni...

Installed Rails but the rails command says it's not installed.

Hey there, I'm using Ubuntu 9.10 Karmic Koala and Ruby 1.9.1. I installed Rails using sudo gem install rails, which installed all the libraries for me. When I type rails in the terminal it says. The program 'rails' is currently not installed. You can install it by typing: sudo apt-get install rails rails: command not found I can fi...

Can't update RubyGems

Hi! I'm having difficulties updating RubyGems from version 1.1.1 to newest. I've tried the following: gem update Result: Updating installed gems Bulk updating Gem source index for: http://gems.rubyforge.org/ Nothing to update and gem install rubygems-update Result: Bulk updating Gem source index for: http://gem...

How best to package rubygems in addition to jruby-complete.jar?

As developing an Java application bundled with 'jruby-complete.jar', it is desired not to put required rubygems localally, but instead packaged it along with the application. Obviously we don't want to touch 'jruby-complete.jar'. What's the better way of packaging these rubygems? ...

How to install rdiscount ruby gem in windows vista ?

I have vista and trying to install ruby gem - 'rdiscount' and get following error..what's the answer for this? $ gem install rdiscount Building native extensions. This could take a while... ERROR: Error installing rdiscount: ERROR: Failed to build gem native extension. c:/Ruby/bin/ruby.exe extconf.rb checking for random()... ...

Problem install do_sqlite3 for DataMapper

sudo env ARCHFLAGS="-arch x86_64" gem install do_sqlite3 Building native extensions. This could take a while... ERROR: Error installing do_sqlite3: ERROR: Failed to build gem native extension. /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby extconf.rb checking for sqlite3.h... yes checking for sqlite3_open() i...

Things to do before upgrading Ruby

What should I do before upgrading to the latest version of Ruby? any tips? Update sorry for my unclear question. my condition: I've upgraded my Ruby from 1.8.7 to 1.9.1p243. It makes me can not use all installed gems. so, what should I do before upgrading Ruby? uninstall all my installed gems? I was looking in other SO posts in here...

no such file to load -- silentale-on-rails (new gem)

I've just completed a new open source gem for the Silentale API and I'm facing a strange issue. In terminal I'm getting an error saying that it can't load the gem however it continues to start the server loading it without any issues. no such file to load -- silentale-on-rails /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in `gem...

Ruby on Rails Win7 x64 ?

Hi, I've just upgraded to Win7 x64 Professional and wanted to recommence developing my Rails Apps, however I'm getting the following error : => Booting Mongrel => Rails 2.3.5 application starting on http://127.0.0.1:3344 D:/nu codes/R/ruby-1.8.7-p174-i386-mswin32/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:271:in `require_fra...

Ruby-Debug Gem Install Problem on Windows

I'm having trouble installing the Ruby-Debug Gem on windows. What does this error mean? How can I fix this? Thanks C:\Users\Steve>gem install ruby-debug Building native extensions. This could take a while... ERROR: Error installing ruby-debug: ERROR: Failed to build gem native extension. C:/Ruby19/bin/ruby.exe extconf.rb Can't han...

Executing a binary gem file with unpacked gems

I am using the gem whenever To update the crontab, it executes the whenever command in the root directory of my application. The trouble is: my production environment doesn't have the gem installed, so I unpacked the whenever gem into my application and running 'whenever' from my application root directory fails to find the file How d...

Does any one know good editor available in RoR for windows?

Does any one know good editor available in RoR for windows? ...

Config.gem in test and cucumber environments

With RSpec and Cucumber, why is it preferred to specify :lib => false in the environment files - and then explicitly require the gems in spec_helper.rb and env.rb? ...

how to set color in ruby pdf-writer

Hi folks. I'm using pdf-writer gem in ruby. While drawing a table, i need to set the shade_color and shade_color2 of table so that the rows get the alternate shade and shade2 colors. Can anyone tell me how to set them? Like table.shade2 = Color::RGB::Magenta But i have a hexa vaue like 989898. Now, how to use this. Any help is appr...

How to add cell-padding or cell-spacing in ruby pdf-writer

Hi folks, I have seen an ocean of options in pdf-writer Simple-Table, but it doesn't seem to have the cell-spacing and cell-padding. 1) Is it implemented, did i miss it? If so, can you plz gimme a line of code. 2) If not implemented, is there any work-around? Any help is appreciated. THanks ...