I have deployed a rails 3.1 app to Heroku Cedar stack, and am trying to perform a:
heroku run rake db:migrate
it returns:
R
It seems this happens for different reasons. For me it turned out to be I had an older version of the Heroku Toolbelt installed. It was prior to the self-updating version and I also had old versions of the heroku gems installed. Those had to be removed before updating the heroku toolbelt had any effect.
This page proved helpful. Read it first: https://devcenter.heroku.com/articles/heroku-command#staying-up-to-date
Find out which heroku toolbelt version (if any) you are using like this:
$ heroku version
heroku-toolbelt/2.xx.x
If it is older than version 2.32.0 then it needs to be updated. If you don't see 'heroku-toolbelt' in the response, then you need to install it.
Make sure you uninstal any old heroku gems first. Running the command below asked me if I wanted to remove the executables as well. The correct answer is YES! You can always bundle/install later if you need the gem for specific apps.
$ gem uninstall heroku --all
If you are using rbenv, you may need to rehash:
$ rbenv rehash
Once you clean out the old gems, download the current heroku toolbelt and install it. Everything should work after restarting the terminal.
EDIT:
I had to make sure my rbenv path didn't get set in front of the heroku cli path. Otherwise any bundle/install of the old heroku gem would hijack the heroku command again. I added the export path line at the end of my ~/.profile file so it would be appended before any rbenv path.
$ vi ~/.profile
export PATH=/usr/local/heroku/bin:$PATH
Reloading the terminal showed this worked by running and the path not being in /usr/local/heroku
$ which heroku
/usr/local/heroku/bin/heroku