2016-06-14 218 views
1

任何人都可以請解釋這些有什麼問題嗎?Heroku - git push

mhsjaber:~/workspace/newsite (master) $ heroku keys:add 
? Which SSH key would you like to upload? /home/ubuntu/.ssh/id_rsa.pub 
Uploading /home/ubuntu/.ssh/id_rsa.pub SSH key... done 

mhsjaber:~/workspace/newsite (master) $ heroku create 
Creating app... done, ⬢ ancient-island-20017 
https://ancient-island-20017.herokuapp.com/ | https://git.heroku.com/ancient-island-20017.git 

mhsjaber:~/workspace/newsite (master) $ git push heroku 
No refs in common and none specified; doing nothing. 
Perhaps you should specify a branch such as 'master'. 
Everything up-to-date 
+0

我的回答對你有幫助嗎? –

回答

0

您必須首先添加一些內容才能推送到heroku服務器。由於您的存儲庫已經在heroku上創建,因此您必須在其上添加您的應用程序,才能執行以下步驟。

(1)heroku login

(2)git init

(3)git add .

(4)git commit -am "comment"

(5)git push heroku master

你的情況

你混淆heroku在你的git push命令中不添加master。