Herokuでデプロイするために行ったこと
①git push heroku master コマンドを実行した
→
git@heroku.com: Permission denied (publickey).
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
となり、デプロイできない。
②githubデスクトップを確認
→Publish branch されてない状態になっている。
https://gyazo.com/8ac4536e5e8467fa1d0bb02b065bfb68
③Publish branchしようとすると
https://gyazo.com/13f90f87bab0c438099a17f8e606c4b8
エラーメッセージが表示される。
Authentication failed. Some common reasons include:
- You are not logged in to your account: see GitHub Desktop > Preferences.
- You may need to log out and log back in to refresh your token.
- You do not have permission to access this repository.
- The repository is archived on GitHub. Check the repository settings to confirm you are still permitted to push commits.
- If you use SSH authentication, check that your key is added to the ssh-agent and associated with your account.
翻訳すると、
認証に失敗しました。一般的な理由は次のとおりです。
-アカウントにログインしていません:GitHubデスクトップ>設定を参照してください。
-トークンを更新するには、ログアウトしてから再度ログインする必要がある場合があります。
-このリポジトリにアクセスする権限がありません。
-リポジトリはGitHubにアーカイブされています。リポジトリの設定をチェックして、コミットのプッシュがまだ許可されていることを確認します。
-SSH認証を使用する場合は、キーがssh-agentに追加され、アカウントに関連付けられていることを確認してください。
となりました。
④再度ログインする必要があると思い、設定を開きました。
https://gyazo.com/4a7857c0447ea784e2d21f817926f0f6
見ると、ログインはできている状態でした。どうして「Publish branch」できないのか、どうすれば解決できるのかご意見を伺いたいです。