'heroku' does not appear to be a git repository

前端 未结 21 2022
失恋的感觉
失恋的感觉 2020-12-12 08:47

When I try to push my app to Heroku I get this response:

fatal: \'heroku\' does not appear to be a git repository
fatal: Could not read from remote repositor         


        
21条回答
  •  挽巷
    挽巷 (楼主)
    2020-12-12 09:10

    First, make sure you're logged into heroku:

    heroku login 
    

    Enter your credentials.

    It's common to get this error when using a cloned git repo onto a new machine. Even if your heroku credentials are already on the machine, there is no link between the cloned repo and heroku locally yet. To do this, cd into the root dir of the cloned repo and run

    heroku git:remote -a yourapp
    

提交回复
热议问题