Tag Archives: Ruby on Rails

Enabling Gzip with ngnix

Gzipping has its advantages, it compresses CSS, JS and HTML so that your response time increases. Lets say that you save 100KB per hit after Gzipping, now say you get 1000 unique hits per day, that will  be 100MB of data saved a day, pretty huge saving. I am using Ngnix now predominantly, so ngnix.conf […]


ROR : TDD / BDD with RSpec : Initial Setup ( Copied )

RSpec Setup in Rails 4 An up-to-date testing environment setup for Rails 4, including RSpec, Capybara, and FactoryGirl. Gems Gems gonna used are:


Quick set up Your Rails App

I am about to begin development on new application with Ruby on Rails. The following tutorial takes you through the first steps I took to generate my blank rails application on mac os x. This is where I will begin… This tutorial expects some prior knowledge of frameworks, ruby, rails, command line, how web applications work, […]


How to create links in Rails

Creating links can be confusing if you are just starting to learn Rails. It is important to understand how your views, controllers, and routes are connected. If you already have an app you are working on, simply type: $rake routes This command will let you see all your routes, how your views connect to your […]


[Part 1] MongoId what you need is not what you get !!

Not all tools are good. You need to know what your tools are, what they do and how to avoid shits (tools always come with shits… just jump over, not into). Mongoid is recommended in MongoDB official site as the first choice for ruby ORM to work with Mongodb… But is it good enough ? In my […]


How to reuse Rspec code with Shared Examples

Rspec Rspec is a BDD (Behavior-driven development) framework for the Ruby language. Rspec uses a DSL language for to write descriptive tests. DRY (Don’t repeat yourself) Some times, we need reuse code on RSpec tests (DRY). A good solution is to use Rspec Shared Examples. Example This is a small example. First we need create […]


Laying out the Building Blocks to get Started

In this tutorial, I am endeavouring to get the base of my app looking how I would like it, so I can create an initial building block to start from. It will enable me to complete models as I go. 1. Following my previous tutorial, I will begin setting up the layout files for my […]