我使用的是git bash
Welcome to Git (version 1.8.1.2-preview20130201)
Run 'git help git' to display the help index.
Run 'git help <command>' to display help for specific commands.
Administrator@PC-201208092033 /c/Windows/system32
$ heroku login
Enter your Heroku credentials.
Email: xxxxxxxxx@yy.com
Password (typing will be hidden):
Authentication successful.
$ cd /d/study/heroku/hello_heroku_php/
Administrator@PC-201208092033 /d/study/heroku/hello_heroku_php (master)
$ heroku create
Creating sleepy-harbor-5621... done, stack is cedar
http://sleepy-harbor-5621.herokuapp.com/ | git@heroku.com:sleepy-harbor-5621.git
Administrator@PC-201208092033 /d/study/heroku/hello_heroku_php (master)
$ git push heroku master
Warning: Permanently added the RSA host key for IP address '50.19.85.132' to the
list of known hosts.
! No such app as limitless-crag-3058.
#报错没有app:limitless-crag-3058。和上面刚刚创建的app:sleepy-harbor-5621同
#因此我们需要删除之前的app:limitless-crag-3058并使用app:sleepy-harbor-5621替换。
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
$ git remote rm heroku
Administrator@PC-201208092033 /d/study/heroku/hello_heroku_php (master)
$ heroku git:remote -a sleepy-harbor-5621
Git remote heroku added
Administrator@PC-201208092033 /d/study/heroku/hello_heroku_php (master)
$ git push heroku master
Initializing repository, done.
Counting objects: 4, done.
Delta compression using up to 3 threads.
Compressing objects: 100% (2/2), done.
Writing objects: 100% (4/4), 300 bytes, done.
Total 4 (delta 0), reused 0 (delta 0)
-----> PHP app detected
NOTICE: Your composer.json is completely empty.
Please change its contents to at least "{}" so it is valid JSON.
-----> No runtime requirements in composer.json, defaulting to PHP 5.5.15.
-----> Installing system packages...
- PHP 5.5.15
- Apache 2.4.10
- Nginx 1.6.0
-----> Installing PHP extensions...
- opcache (automatic; bundled, using 'ext-opcache.ini')
-----> Installing dependencies...
Composer version 4ecdbf89c4a3d1e5dfe73c57e3202a5e2a18c87e 2014-07-28 20:1
2:27
Loading composer repositories with package information
Installing dependencies
Nothing to install or update
Generating optimized autoload files
-----> Preparing runtime environment...
NOTICE: No Procfile, defaulting to 'web: vendor/bin/heroku-php-apache2'
-----> Discovering process types
Procfile declares types -> web
-----> Compressing... done, 62.7MB
-----> Launching... done, v3
http://sleepy-harbor-5621.herokuapp.com/ deployed to Heroku
To git@heroku.com:sleepy-harbor-5621.git
* [new branch] master -> master
Administrator@PC-201208092033 /d/study/heroku/hello_heroku_php (master)
$ heroku open
Opening sleepy-harbor-5621... done
会打开网页: