I am using Ubuntu 10.04. By following the tutorial here, I have created Heroku account, installed GIT and Heroku successfully. I have uploaded the SSH key and add heroku to my system PATH.
After that, I did the following thing:
---------- FIRST (successful)-------------
$ cd PATH/TO/MY_APP
$ git init
Initialized empty Git repository in .git/
$ touch HELLO
$ git add .
$ git commit -m "Add a HELLO file"
$ heroku create
Enter your Heroku credentials.
Uploading ssh public key /Users/joe/.ssh/id_rsa.pub
Created http://high-sunrise-58.heroku.com/ | firstname.lastname@example.org:high-sunrise-58.git
Git remote heroku added
$ git push heroku master
Warning: Permanently added the RSA host key for IP address 'xx.xx.xx.xx' to the list of known hosts.
Counting objects: 3, done.
Writing objects: 100% (3/3), 226 bytes, done.
Total 3 (delta 0), reused 0 (delta 0)
-----> Heroku receiving push
! Heroku push rejected due to an unrecognized error.
! We've been notified, see http://support.heroku.com if the problem persists.
! [remote rejected] master -> master (pre-receive hook declined)
error: failed to push some refs to 'email@example.com:high-sunrise-58.git'
You cannot push any random repo to Heroku. It has to be a rails app ( or any of the other supported apps like Django, but in this case OP is working on Rails) and that is what the pre-receive hook is rejecting in your case since your repo just has some dummy file. ( NOTE that the first step in the tutorial is not creating an empty git repo, but creating one for your Rails app. See the output in the successful push example in the quickstart -
Rails app detected - means it looks for the rails app when you push something.)