Skip to content
Installing Rails plugins from Github on Windows
Posted 2125 days ago

Well, I have installed several Rails plugins but I was bummed when I tried to install the re-captcha plugin from Github. The command belwo just fails silently and creates an…

How to print a document as a booklet
Posted 1106 days ago

After spending about an hour, reams of pages, and pails of ink, I finally stumbled into the magic of booklet printing. My source document was a MS-Word 2010 document with…

How to print a document as a booklet
How to install RMagick + ImageMagick on Windows
Posted 1888 days ago

I have installed RMagick and Image Magick on many Windows machines and I have stumbled across various kinds of errors, and finally I have decided to document them so that…

Installing gems behind proxy servers
Posted 2545 days ago

It is well documented as part of gem help that using the following common options:

-p, --[no-]http-proxy [URL]      Use HTTP proxy for remote operations

will allow gem to use the proxy server…

ruby-alibris wrapper wins
Posted 1339 days ago

I had blogged about my recent open-source project, a Ruby wrapper for the Alibris API, ruby-alibris. Soon after, Alibris had announced their First Annual Alibris API Programming Contest, and I submitted…

Playing with CoffeeScript
Posted 1507 days ago

After having used Haml and Sass and loving them, a friend introduced me to CoffeeScript. In short CoffeeScript is to Javascript as Haml is to Html and Sass is to…

Playing with CoffeeScript
Error in Ruby relative_path_from call on Windows
Posted 1745 days ago

I was recently working on some code for building an extension for Spree, when I ran into an issue while generating a extension controller. The error only happens on Windows.

The…

Rails Magazine releases free Issue #5 digital edition
Posted 1894 days ago

Themed in beautiful Winter art and pictures, Rails Magazine released their Issue #5 free digital edition to the whole Ruby and Rails community worldwide.

It is the largest issue since we…

Rails Magazine releases free Issue #5 digital edition
Tip: has_one and nested form/attributes
Posted 2029 days ago

Although, the usage of nested forms with has_many associations is well documented, I found that especially the call ..build that works for has_many associations do not work for has_one associations.…

Install SQLite3 on Windows
Posted 2108 days ago

I found this great screencast that shows how easily you can install SQLite3 on Windows. So, here you go:

Install SQLite3 on Windows

PreviousNext
Feb 4 / Rupak Ganguly

Docker is good, Panamax is awesome

Digg This
Reddit This
Stumble Now!
Buzz This
Vote on DZone
Share on Facebook
Bookmark this on Delicious
Kick It on DotNetKicks.com
Shout it
Share on LinkedIn
Bookmark this on Technorati
Post on Twitter
Google Buzz (aka. Google Reader)

I presented at ATLRUG on Panamax, an open source management system for Docker. Directly working with Docker can be very challenging and in many cases one must his apps on his own. Panamax is a containerized app creator with an open-source app marketplace hosted in GitHub. Panamax provides a friendly interface for users of Docker, Fleet and CoreOS.

Video

The video for the presentation is also available at: http://youtu.be/Nj_Jn6pjLPA

This presentation was recorded at the November, 2014, meeting of the Atlanta Ruby Users’ Group. Learn more about our community at http://www.atlrug.com.

Slides

The slides for the presentation are available for download at https://speakerdeck.com/rupakg/2014-atl-ruby-meetup-remote-deployments-with-panamax.

To read more about Docker and Panamax, visit CenturyLinkLabs blog.

Aug 11 / Rupak Ganguly

How to manage whitespace around text in Haml?

Digg This
Reddit This
Stumble Now!
Buzz This
Vote on DZone
Share on Facebook
Bookmark this on Delicious
Kick It on DotNetKicks.com
Shout it
Share on LinkedIn
Bookmark this on Technorati
Post on Twitter
Google Buzz (aka. Google Reader)

While creating some html content using Haml, I ran into the problem of removing the extra space that Haml puts in after a link text. Here is what I wanted the link text to look like:

Check out my website.

But, what I got was: (note the extra space before the period)

Check out my website .

It drove me nuts trying to fix it before I discovered the cool new Haml helpers. The particular helper in question that fixed the above issue is the succeed helper method as shown below:

%strong
   Check out my
   = succeed '.' do
       %a{href: 'http://rails.webintellix.com'} website

Hope that helps you to write good html using Haml.

If you have other Haml tricks you know of, let me know in the comments section.

Nov 13 / Rupak Ganguly

Ruby wrapper for PunchTab API

Digg This
Reddit This
Stumble Now!
Buzz This
Vote on DZone
Share on Facebook
Bookmark this on Delicious
Kick It on DotNetKicks.com
Shout it
Share on LinkedIn
Bookmark this on Technorati
Post on Twitter
Google Buzz (aka. Google Reader)

A while back, in May 2013, I had worked on writing a Ruby wrapper for the PunchTab API. I found the concept of PunchTab‘s loyalty program interesting, and wanted to integrate that into my web apps. So, I wrote the wrapper. See the code snippets below, to see how to use the wrapper to access PunchTab’s loyalty programs.

read more…

Feb 24 / Rupak Ganguly

How to print a document as a booklet

Digg This
Reddit This
Stumble Now!
Buzz This
Vote on DZone
Share on Facebook
Bookmark this on Delicious
Kick It on DotNetKicks.com
Shout it
Share on LinkedIn
Bookmark this on Technorati
Post on Twitter
Google Buzz (aka. Google Reader)

After spending about an hour, reams of pages, and pails of ink, I finally stumbled into the magic of booklet printing. My source document was a MS-Word 2010 document with 18 pages, which I wanted to print as a 2-sided, 2-pages per sheet, booklet on Letter paper. Although, MS-Word comes with an option to print a document as a booklet as shown below,

booklet_printing_1

 

it is impossible to get it right, the way you expect it. It would print page 1 and 7 one side of the sheet, while you would expect it to print 1 and a blank. Just tried every other possibility, even with odd numbered pages, but I had no luck.

read more…

Jul 6 / Rupak Ganguly

ruby-alibris wrapper wins “Most Developer-Friendly Code” award

Digg This
Reddit This
Stumble Now!
Buzz This
Vote on DZone
Share on Facebook
Bookmark this on Delicious
Kick It on DotNetKicks.com
Shout it
Share on LinkedIn
Bookmark this on Technorati
Post on Twitter
Google Buzz (aka. Google Reader)

I had blogged about my recent open-source project, a Ruby wrapper for the Alibris API, ruby-alibris. Soon after, Alibris had announced their First Annual Alibris API Programming Contest, and I submitted the ruby-alibris project as an entry. And, to my surprise, I got notified that it won the “Most Developer-Friendly Code”, and a $250 cash prize. Today, Alibris released a press release announcing the winners. Here is an excerpt from the press release:
read more…

May 15 / Rupak Ganguly

Ruby wrapper for Alibris API

Digg This
Reddit This
Stumble Now!
Buzz This
Vote on DZone
Share on Facebook
Bookmark this on Delicious
Kick It on DotNetKicks.com
Shout it
Share on LinkedIn
Bookmark this on Technorati
Post on Twitter
Google Buzz (aka. Google Reader)

I recently wrote a Ruby wrapper (ruby-alibris) for the Alibris API. I started with the Search API, and I would finish the wrapper with the Recommendations and Reviews shortly. Read the documentation below and give it twirl. I would be interested in your comments and feedback. Alibris, is the premier online marketplace for independent sellers of new and used books, music, and movies, as well as rare and collectible titles.

read more…

Jan 19 / Rupak Ganguly

Playing with CoffeeScript

Digg This
Reddit This
Stumble Now!
Buzz This
Vote on DZone
Share on Facebook
Bookmark this on Delicious
Kick It on DotNetKicks.com
Shout it
Share on LinkedIn
Bookmark this on Technorati
Post on Twitter
Google Buzz (aka. Google Reader)
After having used Haml and Sass and loving them, a friend introduced me to CoffeeScript. In short CoffeeScript is to Javascript as Haml is to Html and Sass is to CSS. Not so strictly speaking but lets roll with this for now. So here is my how-to article to share my thoughts and experience, while I played with it.
What is CoffeeScript and why do you care?
Instead of me, making something up, here is what the CoffeeScript site has to say:
“CoffeeScript is a little language that compiles into JavaScript. Underneath all of those embarrassing braces and semicolons, JavaScript has always had a gorgeous object model at its heart. CoffeeScript is an attempt to expose the good parts of JavaScript in a simple way.
The golden rule of CoffeeScript is: “It’s just JavaScript”. The code compiles one-to-one into the equivalent JS, and there is no interpretation at runtime. You can use any existing JavaScript library seamlessly (and vice-versa). The compiled output is readable and pretty-printed, passes through JavaScript Lint without warnings, will work in every JavaScript implementation, and tends to run as fast or faster than the equivalent handwritten JavaScript.”
Read more or try in your browser at the CoffeeScript website.
Jan 19 / Rupak Ganguly

Rails Installer on Windows

Digg This
Reddit This
Stumble Now!
Buzz This
Vote on DZone
Share on Facebook
Bookmark this on Delicious
Kick It on DotNetKicks.com
Shout it
Share on LinkedIn
Bookmark this on Technorati
Post on Twitter
Google Buzz (aka. Google Reader)

If you are like me, I started my Ruby on Rails development on Windows and I had my issues with installing the stack. I had issues with gems especially the ones with C-extensions. But, things have changed dramatically over the years and things are much smoother now. A great example of getting the Rails stack installed on Windows is: Rails Installer.

The Rails Welcome Kit has everything you need to hit the ground running. In one easy-to-use installer, you get all the common packages needed for a full Rails stack. Download it now and be writing (and running) Rails code in no time. Packages included are:

  • Ruby 1.8.7-p330
  • Rails 3.0.3
  • Git 1.7.3.1
  • Sqlite 3.7.3
  • DevKit

Watch the RailsInstaller Introduction from Engine Yard on Vimeo.

Nov 2 / Rupak Ganguly

Rails Magazine Issue #7 released

Digg This
Reddit This
Stumble Now!
Buzz This
Vote on DZone
Share on Facebook
Bookmark this on Delicious
Kick It on DotNetKicks.com
Shout it
Share on LinkedIn
Bookmark this on Technorati
Post on Twitter
Google Buzz (aka. Google Reader)
Rails Magazine Issue #7

Rails Magazine Issue #7

We are happy to bring you the Issue #7, 2010 of Rails Magazine. We are trying our best to fall into a regular publishing schedule. In this edition, we have a very nice collection of articles. I am also very happy to have penned down the editorial for this edition.

In the 28-pages of full color, we bring you the following:

  • Editorial by Rupak Ganguly
  • An Overview of Refinery – a Rails CMS by David Jones
  • Converting A Rails Site to Refinery CMS by Christopher W. Lehman
  • Auditing plugin by Mihai Târnovan and Gabriel Târnovan
  • Hobo – Making Application Development on Rails Even Faster by Dave Reynolds
  • Installing Ruby on Rails on Windows by Victor Thiago
  • Simple Unobtrusive Ruby/Rails Debugging by Stephen Rycyk
  • A Well Kept Secret, Ruby and Cryptography by Richard Penwell

The digital edition (PDF) is available for free at http://www.railsmagazine.com/issues/7. You can also grab a printed copy available in US, UK and Canada (7.60 USD + shipping).

Download the free digital edition of Rails Magazine Issue #7.

Jun 29 / Rupak Ganguly

Rails Magazine Issue #6 released

Digg This
Reddit This
Stumble Now!
Buzz This
Vote on DZone
Share on Facebook
Bookmark this on Delicious
Kick It on DotNetKicks.com
Shout it
Share on LinkedIn
Bookmark this on Technorati
Post on Twitter
Google Buzz (aka. Google Reader)
Rails Magazine Issue #6

Rails Magazine Issue #6

I am very happy to announce the release of the Rails Magazine Issue #6. It took us a while to get this issue out but it is better late than never. We improved a lot on the backend side and revamped into a new automated publishing system. This will in future enable us to streamline the author submission, editing and publishing process. Olimpiu and Raluca Metiu, the husband/wife combo, worked very hard to get the new publishing system up.

In this beautiful 36-pages full color issue you will find some very in-depth articles and a couple of nice interviews. The issue consists of the following:

  • Beautifying Your Markup With Haml and Sass by Ethan Gunderson
  • Scaling Rails by Gonçalo Silva
  • Interview with Sarah Allen by Rupak Ganguly
  • Data Extraction with Hpricot by Jonas Alves
  • Deployment with Capistrano by Omar Meeky
  • Fake Data – The Secret of Great Testing by Robert Hall
  • RubyConf India 2010 coverage by Judy Das
  • Previous and Next Buttons by James Schorr
  • RVM – The Ruby Version Manager by Markus Dreier
  • Interview with Michael Day of Prince XML by Olimpiu Metiu

The digital edition (PDF) is available for free at http://www.railsmagazine.com/issues/6. You can also grab a printed copy  available in US, UK and Canada (8.80 USD + shipping).

Download the free digital edition of Rails Magazine Issue #6.