Skip to content

Instantly share code, notes, and snippets.

View Luminus's full-sized avatar

Luminus Olumide Alabi Luminus

View GitHub Profile
@Luminus
Luminus / gist:bcb2fb4c032dd33d3de8
Created February 1, 2015 01:26
I had to run this to enable the pg gem in my app work. This way I can use postgre on my development computer and also push to heroku. The --with-pg-config bit tells the gem how to find my postgre install confiurations.
gem install pg -- --with-pg-config=/opt/local/lib/postgresql94/bin/pg_config
@Luminus
Luminus / pg_start.sh
Created February 1, 2015 01:13
I installed postgresql on my mac using MacPorts and created these scripts so I can easily start and stop the server without going nuts. I put these scripts in my personal /bin at ~/bin/ and run chmod +x on them
#!/bin/bash
sudo su postgres -c '/opt/local/lib/postgresql94/bin/pg_ctl -D /opt/local/var/db/postgresql94/defaultdb -l /opt/local/var/db/postgresql94/defaultdb/postgresql.log start'