Getting Started: Ruby with PostgreSQL for Mac

Ruby has become such a key element in modern web development that data access to PostgreSQL from Ruby is almost a a required element.  Ruby has a built in tool for installing modules that is well known in Gem.    The gem install tool is easy, but sometimes requires a little bit of massaging.  Two of the popular PostgreSQL gems are postgres and pg.  Both can be installed with gem using this PostgreSQL installation:

postgres:

sudo gem install postgres -- --with-pgsql-dir=/Library/PostgreSQL

pg:

sudo gem install pg -- --with-pg-dir=/Library/PostgreSQL