How to attach my repo to heroku app

后端 未结 3 545
無奈伤痛
無奈伤痛 2020-12-12 10:47

I create a heroku app and then my machine crashed. I have a new machine. How do I attach my existing app to heroku app. When I visit heroku page the url for my app is like t

3条回答
  •  执念已碎
    2020-12-12 11:25

    If you're using just Git without installing the Heroku Toolbelt, you can also create a new application.

    Login to your account and go to this link

    https://dashboard.heroku.com/apps

    Look at the plus sign on the top right corner then select

    Create new app

    Leave the application name blank to let heroku choose one for you. Let say your heroku app name is new-app-xxxxx, so to test on adding a file in to it you may try the following command:

    git clone https://git.heroku.com/.git
    cd 
    echo "my test file" > test.txt
    git add .
    git commit . -m "my test on commit" 
    git push
    

    Put empty (blank) when the Git prompt for username, and your API Key for the password. You can get your API Key by showing it from the link below.

    https://dashboard.heroku.com/account

    Note: You cannot authenticate with the Heroku HTTP Git endpoint using your Heroku username (email) and password. Use an API key as described here.

提交回复
热议问题