I just learned about rake db:system:change task that Rails provides, to speed up switching between different database engines. If you’re experimenting with something, or benchmarking things, this is super useful.
Category: Ruby & Rails
Starting new Rails applications
It’s been a while since I reviewed the documentation for rails new console command. There are a few useful features that I didn’t know about:
Speeding up office work with Ruby and IRB
I was just paying taxes ?. One of the steps involved was copying and pasting a few long reference numbers from a PDF into my banking app. The thing is, when copied, the reference number would contain extra spaces, after each character, making it invalid where I needed to paste it.
Don’t forget about X-Forwarded-Host header
Recently I was working on a Rails application on Heroku living behind a reverse proxy. This application serves requests coming to a specific folder on the target domain. For it to correctly generate full URLs, you have to somehow tell this app the hostname you want it to use. In Rails, you can configure a hostname in the environment config file, but that’s a static value, which has to be maintained and changed per environment. Also it does not work well if you want to access the application from multiple domains.
CRM system
Integrated business management web app for a sales company with CRM features. The functionality this Rails app provides is extensive:
Speeding up bundle install with in-memory file system
On some of the servers I work with, due to cheap hard drives in software RAID configuration, I’ve found that bundle install can be extremely slow (take half an hour to complete). This obviously became unacceptable during deploys.
Effort – Personal To-do and Project manager
I open sourced a Rails app that I’ve been personally using for years for simple project management. The code is available on Github under the MIT license. From the README:
EQAFE – Ecommerce
This is one of the first projects where I started using Rails in production. EQAFE developed—over the years—from a simple checkout page to sell a single book to an ecommerce platform featuring thousands of products, affiliate program, gifts and more.
DIP Lite: E-learning Platform
DIP Lite is a free e-learning platform. Its fully automated in-browser experience connects the users with a personally assigned “buddy”: an experienced person that overviews and assist the user throughout the course. The user walks the course on her own pace as well as engage in daily exercises, complete with email notifications and communication with the course buddy provided by the course platform.
Projects Overview in 2012
These are some of the projects I’ve launched during 2012. This year was interesting as I switched from mainly using PHP as a backend language to Ruby (on Rails). Switching to Ruby was a welcome refreshment, the syntax is so close to natural language. I really enjoy the way it allows one to express the idea in code. There is little I need to say about Rails.