2014-02-21 79 views
7

我在Heroku儀表板中將我的應用名稱從「my-app-staging」更改爲「my-app-staging-new」。現在我不能再對它進行更改 - git會拋出下列錯誤:Heroku應用名稱更改後Git推送失敗

! No such app as my-app-staging.

fatal: Could not read from remote repository.

如何解決該問題?

+0

[重命名的heroku應用程序可能來自網站的重複,現在找不到](http://stackoverflow.com/questions/7615807/renamed-heroku-app-from-website-now-its-not-found) – Yarin

回答

20

你需要改變你的git remote。

如果你做git remote -v你應該看到heroku列出。

它看起來是這樣的:

heroku [email protected]:my-app-staging.git (fetch)
heroku [email protected]:my-app-staging.git (push)

刪除遠程...

git remote rm heroku

...然後添加新的

git remote add heroku [email protected]:my-app-staging-new.git