For the longest time I’ve deal with internationalization in Ruby on Rails by hand. This is a tedious process that involves switching back and forth between the file containing the string and your localization yaml file. I was looking at Ruby Mine and found that it supports localization and appears to do many of the…
Category: Ruby On Rails
Heroku
I’ve watched Heroku for a while. I’ve even tried to deploy an app there a few times, but never got into it that much. I needed a cheap (free) place to put My Amazon Feeds.com. It’s just a utility site. It’s not meant to scale or be production worthy. Instead it’s meant to show off…
River – Amazon Wishlist Gem
One more post on Amazon Wishlist code. As another follow up to my post on Amazon Wishlist RSS, Ruby and Signing/Authenticating your Requests and the site I built to run the code My Amazon Feeds (post here) I’ve created a gem to contain all the code. Get it by running sudo gem install river </pre>…
no configured for
If you are using Jeweler and get this error: no configured for Check out the troubleshooting section: You need to edit ~/.rubyforge/auto-config.yml and make sure processor_ids is set like this: processor_ids: IA64: 6000 AMD-64: 1500 Any: 8000 Sparc: 4000 PPC: 2000 Other: 9999 Alpha: 7000 i386: 1000 UltraSparc: 5000 MIPS: 3000
Gems on an EngineYard Solo instance
I started running into a few issues on an Engineyard Solo instance with my muck gems. Basically, muck consists of a lot of Rails engines packaged as gems for reusability. When we release a new app we also need to release new versions of the gems since that’s where most of guts of the lives….
gems:unpack for gems that don’t unpack
I couldn’t figure out why my gems wouldn’t unpack until I ran across this: http://metaclass.org/2009/4/13/rake-gems-unpack. My gems have rake tasks and I have to include them in the app’s rakefile to make them available so Rails won’t unpack them. I did this instead: def muck_gems [‘cms-lite’, ‘disguise’, ‘uploader’, ‘muck-solr’, ‘muck-raker’, ‘muck-engine’, ‘muck-users’, ‘muck-activities’, ‘muck-comments’, ‘muck-profiles’,…
Amazon Wishlist RSS, Ruby and Signing/Authenticating your Requests
UPDATE: If you don’t want to bother with the code and instead would just like to get your Amazon.com Wishlist rss you can go here. I’ve been playing with the Amazon API lately. At first I just wanted to get the RSS feed to my wish list and I followed the direction in this article…
to_json gives TypeError Exception: wrong argument type Hash (expected Data)
Tonight for no apparent reason my tests started turning up this error whenever I tried to call to_json: TypeError Exception: wrong argument type Hash (expected Data) </pre> Specifically, my to_json call looked like this: respond_to do |format| format.js { render :json => @states.to_json(:only => [:id, :name]) } end </pre> In the debugger .to_json worked but…
Updating Genlighten from Rails 2.2.2 to Rails 2.3.2
I can’t resist new stuff so I’m updating Genlighten to Rails 2.3.2. This release comes with some pretty sweet additions like Rack. Here’s what I had to do: Set RAILS_GEM_VERSION = ‘2.3.2’ (easy) Removed stuff like this from my code: protect_from_forgery :except => :swfupload session :cookie_only => false, :only => :swfupload </pre> — ‘The :digest…
Interesting testing issue with Rails 2.3.3
I’m not sure if this applies to all the versions of Rails, but right now I’m using the latest 2.3.3. I’m using shoulda to do testing and my code looks like this: context “GET show” do setup do @feed = Factory(:feed) get :show, :id => @feed.to_param end should_not_set_the_flash should_respond_with :success should_render_template :show end </pre> The…