rubygems

How can I render a transparent gradient with RMagick?

Want to use RMagick to create a PNG image of a gradient that goes from rgba(0,0,0,0.3) to rgba(0,0,0,0.7). Is this possible? ...

How to deal with Denial of Service attack and Session fixation and Cross Site request forgery in Rails?

Hi, I have just started learning Ruby on Rails. I happened to look for prevention of DNS attacks in Rails and ended up reading about DNS, Session fixation and Cross Site request forgery in Rails? How do you prevent all the above three attacks?? Could you suggest me a good tutorial on how to deal with attack in RoR? Looking forward f...

Help debugging Ajaxful_rating

I'm in a bit over my head with debugging ajax calls on this, wondering if anyone can help me out. I followed all the directions in the readme, the one tricky thing is my user model is both the rater and the one being rated, not sure if that makes a difference. I'm rating across four dimensions, [:overall, :knowledgeable, :punctual, :fr...

How do you check the Gem Version in Ruby at Runtime?

Is it possible to check the gem version of the currently loaded gem in a ruby/rails app? During debugging, I would like to be able to do something like: puts RubyGem.loaded_version(:active_support) Anything like that exist? ...

Installing The ruby-gmail rubygem on Mac OS Snow Leopard

I'm working off these instructions: http://github.com/dcparker/ruby-gmail From the home directory I do a standard install and good stuff happens: Johnny-Goodmans-MacBook-Pro:gmail johnnygoodman$ sudo gem install ruby-gmail Successfully installed ruby-gmail-0.2.1 1 gem installed Installing ri documentation for ruby-gmail-0.2.1... Insta...

installed gems activated before frozen gems?

We're using gems:unpack to ensure gem version consistency across environments. However, we're running into: can't activate , already activated [GEM-VERSION] Is this because installed gems take precedence over frozen ones? Is it possible to have frozen gems activate first? Advice on ways to keep gems consistent welcome. ...

autospec and missing gem

Hi, i've got a strange behavior or autospec. On autospec run i see in console /opt/local/bin/ruby /opt/local/lib/ruby/gems/1.8/gems/cucumber-0.7.3/bin/cucumber --profile autotest-all --format rerun --out /var/folders/xx/xxbiSMYpEjesle1hezvfDU+++TI/-Tmp-/autotest-cucumber20100603-46558-rwbmlp-0 Missing these required gems: cucumber-ra...

Customizing the Stars Image for Ajaxful_Rating RoR plugin

I'm trying to come up with my own star image that's slightly smaller and different style than the one provided in the gem/plugin, but Ajaxful_rating doesn't have an easy way to do this. Here's what I've figured out so far: The stars.png in the public folder is three 25x25 pixel tiles stacked vertically, ordered empty star, normal star...

Bundler http auth support

does anyone know if Bundler supports http auth? I'm pretty sure rubygems does (I think i read that somewhere) but I don't see anywhere in the docs where I might specify a username/pwd for a particular repo I'm trying to run my own private gem server so as not to expose sensitive code ...

Installing rake

we tried to install rake on our pc but there were following errors.. We even tried updating gems but in vain. We need to run some tasks on rake and dont know how to go abt it. C:\Documents and Settings\nemanich\My Documents\gems>gem install rake-compi 0 .7.0.gem ERROR: http://gems.rubyforge.org/ does not appear to be a repository ER...

no such file to load -- for several gems unpacked in a Rails 2.3.8 app

Hi, I unpacked several gems into the /vendor/gems folder, and I get the same error message for 5 of these gems when I try to start my Rails application. The date-performance one as an example : no such file to load -- date_performance.so /opt/ruby-enterprise-1.8.7-20090928/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:36:in `gem_o...

Rails: How do I include gem dependencies?

This is a noob question: How do I add gems to my rails app in a way that I can just copy my app's directory structure to a remote location and have it just work, with all the gems I depend on installed and available? ...

How to delete a gem path?

Hi there, how can I delete the second path (/home/tom/.gem/ruby/1.8) of "GEM PATHS:" ? Here's the output of "$ gem env": RubyGems Environment: RUBYGEMS VERSION: 1.3.5 RUBY VERSION: 1.8.7 (2009-06-12 patchlevel 174) [i486-linux] INSTALLATION DIRECTORY: /usr/lib/ruby/gems/1.8 RUBY EXECUTABLE: /usr/bin/ruby1.8 EXECUTABLE DIRECTORY: /us...

What's a good way to set up a development environment on OS X for ruby, rails, and git?

I'm going to start development on a web app using ruby, rails, probably either postgres or mysql, and most likely apache. I'll be using a git repository with the master repo on another server. I've searched through stackoverflow and done some Googling... so here's what I have so far... What are your opinions on what's described on this...

Ruby Debug IDE error : ruby-debug-ide-0.4.9/lib/ruby-debug-ide.rb:109:in `debug_load'

I hope someone can assist me. I have RubyMine 2.0.2 installed on Windows 7 32 bit computer. Since a week ago (I presume it must have been after I have update some gems) I cant seem to debug form the IDE. I am trying to debug a rake task which I could before. Running the rake task normally works perfect, just debug doesnt. Its not just li...

How do I use Haml in a view in my new plugin?

I'm creating a new plugin for a jruby on rails application that will eventually be turned into a gem. Inside my plugin I have controllers, helpers and views. For my views I'd like to use Haml. The problem is that I can't seem to get it to recognize that they are haml templates. Is it even possible to do this? Is there a way for a plugin ...

Rubygems optional dependencies

How do I add optional dependencies to rubygems, as it does not support it? Use cases: I have a library that does either depend on Backports, Extlib, Facets or ActiveSupport. In the past I just did not add any of this dependencies, as people could choose (read: it would play nicely with whatever they were using), but people complained ...

Sinatra Gem install error

I have been trying to install sinatra in a macbook running leopard system, and I am not able to do it. I get the following error. MacBook:rubygems-1.3.7 lakshmanan$ gem install sinatra WARNING: RubyGems 1.2+ index not found for: http://rubygems.org/ RubyGems will revert to legacy indexes degrading performance. Bulk updating Gem sourc...

unable to update gems on mac osx - Gem::RemoteFetcher::FetchError

Jon-MacBook-Pro:rubygems-1.3.7 jon$ sudo gem install rails Password: ERROR: While executing gem ... (Gem::RemoteFetcher::FetchError) SocketError: getaddrinfo: nodename nor servname provided, or not known (http://rubygems.org/gems/activesupport-2.3.8.gem) ...

gem problem on mac os x

Just to make one thing clear, it's not completely a programming question but a programmer might know what's wrong: Messed up my gem installation. If I execute "gem list" or any other gem command, I get /Library/Ruby/Site/1.8/rubygems.rb:956:in `use_paths': undefined method `join' for #<String:0x101786480> (NoMethodError) from /Librar...