rubygems

why i cant use gem install command (linux/ ruby / rails)

hi all I'm having problems when issuing 'gem' command I have both rubygems1.8 and rubygems1.9 my rails version is rails-2.3.3 my ruby ruby 1.8.7 and i'm on linux my problem is i cant issue 'gem install ' , instead i have to give 'gem1.8 install ' can anyone tell me why is that ?? thanks in advance cheers sameera ...

How to distribute ruby software?

Hi i am serching for the best way to distribute ruby software (can be open or commercial) to clients: - with less software installed on client (only ruby interpreter) - without less user interaction for updates Any idea? I can use gem but it needs to install rubygems and not fit with commercial software. ...

RubyGems Environment (Snow Leopard)

Greetings, My question is why do I have 3 separate gem paths. My 'gem environment' command displays the following: GEM PATHS - /Library/Ruby/Gems/1.8 - /Users/adam/.gem/ruby1.8 --This one makes sense to me - /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/gems/1.8 Why the two separate "system" paths? Thanks...

Authlogic/OpenID Authentication Fails Using Warp Drive

Warp Drive is a nice way to package an entire Rails application into a Gem for use in other Rails applications. I've gotten Warp Drive to work for a blogging engine I'm creating. There's just one problem - Authlogic OpenID authentication fails. I created a bare-bones OpenID example application. I can compile to a gem with no problems: ...

Gem bundle throws wrong argument type error

I am trying to follow this tutorial and I get the following error which turns up no google results and I'm still too inexperienced to know how to fix it. Any suggestions? ERROR: While executing gem ... (TypeError) wrong argument type Symbol (expected Proc) I am not even sure what gem bundle does exactly so I am not sure where to ...

Suggestions on making multi-language web site.

I am writing a site with more than one language, is there any easy way or technique to reduct the workload of changing which text to another language.I have an idea, but I don't know whether it is suitable or easy enough. I create a XML that contain all the text in my web, when the user change their language, my program will base on the ...

One to many relationship in ROR using Formtastic

following up with this topic: http://stackoverflow.com/questions/1992094/one-to-many-relationship-in-ror I am creating a category that may have many products. So, I use the Formtastic as user Chandra Patni suggested. But I find there is a problem when I added attr_accessible to the product.rb. class Product < ActiveRecord::Base valid...

RadRails (Eclipse plug-in) not recognizing 1.9.1 ruby features.

I installed RadRails as a plugin to eclipse, and I set the interpreter to C:\ruby, the location of my ruby installation. I've also installed RubyGems 1.3.5 via the ruby setup.rb script. When I run the following, however, I get syntax errors in eclipse, although running works. test = { raw: '1', symbols: '2' } p test Furthermor...

Extending a ruby gem in Rails

Let's say I have a Rails app that gets most of it's functionality from a gem (for instance, a CMS). If I now need to add some customisation (for instance, add a property to a user) what is the best practice way of doing this? If I customise the gem, then I will have issues with updating the gem in the future. What is the best approach...

Updating an unpacked and customised gem

We have an interesting scenario I need to sort out: 1) We have an existing application running with an unpacked gem 2) The application has some customisations to the unpacked gem 3) I would like to somehow "merge" a new version of said gem into this unpacked gem to bring it up to date. Any ideas on a nice way of doing this? All the c...

What can I expect as the core stack for Rails 3.0 and what will I need to include now as a plugin

So Rails and Merb are sort of merging in Rails 3.0? Thats how its been described to me anyway. This means that a lot of what made Rails, Rails will now be moved to plug-ins so that it can be more lightweight. HOwever, what are those plug-ins going to be and as a new Rails developer, what are THE must have - and also more mature - plug-in...

Set the font color in prawn

Im using prawn to generate a PDF output in a rails app. How do i change the color of the outputted text? ...

Name conflict when installing a ruby gem

I am hosting a ruby gem repository which hosts several of my gems for my applications. I am running into some problems when I try to install one of my gems that has the same name as a gem on rubyforge. gem.config --- :benchmark: false :update_sources: true :verbose: true :backtrace: false :sources: - http://gems.rubyforge.org - http:/...

'rails' command creates directory with /vendor/rails which uses wrong version of rails

For some reason when I run rails command, it installs 2.2.3 version of Rails in /vendor/rails and webbrick uses that version instead of 2.3.5 which is installed as a gem. If I delete that, then it uses the right directory. I remember using git submodule once, but I don't think that has anything to do with this. How can I correct this? ...

Any way to add gems to specific environments using Rails Template?

I'm building my Rails template right now. Rails template is a way to generate a skeleton app. http://railscasts.com/episodes/148-app-templates-in-rails-2-3 http://m.onkey.org/2008/12/4/rails-templates I would like to add some gems to test.rb and development.rb, but not environment.rb. But I don't find a way to do so other than manua...

Are there any Ruby gems for easy to do image uploading?

Possible Duplicates: Uploading files in Ruby on Rails Uploading files in Rails Uploading Pictures Ruby on Rails I am doing a web site which allow users to upload images, is there any way to simplify the upload process? ...

Overriding Rails Error (Validation) Messages from Gems/Plugins

Is there a generally accepted way of overriding error (validation) messages from a gem/plugin in rails? For example, I'm using the ActiveMerchant gem, and if someone puts in an American Express credit card number, but selects 'MasterCard', I get a not-very-descriptive "Type is not the correct card type" error. I can easily get around t...

Problem with gem loading

Hello, I struggle to have gems correctly loading in a Snow Leopard environment. I installed ruby and rubygems in '/usr/local' (from http://hivelogic.com/articles/compiling-ruby-rubygems-and-rails-on-snow-leopard/ instructions), I installed some gems with 'gem install gem-name'. I correctly see the gem list: $ gem list *** LOCAL GEMS ...

Ruby OSA gem install problem

Trying to install rubyOSA on my iMac sudo gem install rubyosa I get the following error: ERROR: Error installing rubyosa: ERROR: Failed to build gem native extension. /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby extconf.rb mkmf.rb can't find header files for ruby at /System/Library/Frameworks/Ruby.framewo...

Rails - Passing a collection to the layout for will_paginate?

I have my <%= will_paginate %> code block in the layout of my application. I'd like to pass this block different collections depending on what controller/action I'm in. How can I do this? ...