If you're having issues installing a specific gem after installing ruby through Homebrew (as advised above), try the following:
sudo gem install -n /usr/local/bin GEM_NAME_HERE
Found this thanks to user endoplasmic on this issue thread: https://github.com/sass/sass/issues/1768