【发布时间】:2016-12-20 13:37:12
【问题描述】:
每次我想提交命令“git push heroku master”时,都会在 PowerShell 中要求我输入凭据。当我输入 heroku 凭据(默认连接到 git)时,我收到错误消息。
但是,当我在我的主目录中键入 netrc 文件中包含的凭据时,事物就会起作用。然而,在我看来,密码是散列的。如何避免每次将更改推送到 git 时都输入凭据?
更新:
PS C:\Users\Dragan\heroku_workspace\python-getting-started> git push heroku master
github --credentials get: github: command not found
Username for 'https://git.heroku.com': my-email@hotmail.com
Password for 'https://my-email@hotmail.com@git.heroku.com':
github --credentials erase: github: command not found
remote: ! WARNING:
remote: ! Do not authenticate with username and password using git.
remote: ! Run `heroku login` to update your credentials, then retry the git command.
remote: ! See documentation for details: Https://devcenter.heroku.com/articles/http-git#authentication
fatal: Authentication failed for 'https://git.heroku.com/mysterious-river-71834.git/'
【问题讨论】:
-
您收到的错误信息是什么?你应该只需要
heroku login一次。 -
@Harrison 使用我的 heroku 凭据使用命令和 heroku 登录功能。但是,当我输入与以前相同的凭据时,命令 git pushe heroku master 不会。它仅在我输入在 netrc 文件中找到的散列密码时起作用,除此之外,我每次想要执行 git push 时都必须这样做......错误消息在我更新的问题描述中问题。