我最近在 GitHub 上更改了我的个人访问令牌,我想我已经把新令牌放在了所有正确的地方......但也许我错过了一个地方?
问题:
$ git push staging my_cool_branch:master
...
...
...
remote: -----> Installing dependencies using bundler 2.2.33
remote: Running: BUNDLE_WITHOUT='development:test' BUNDLE_PATH=vendor/bundle BUNDLE_BIN=vendor/bundle/bin BUNDLE_DEPLOYMENT=1 bundle install -j4
remote: Fetching gem metadata from https://rubygems.org/.......
remote: Fetching gem metadata from https://rubygems.pkg.github.com/private_org/.
remote:
remote:
remote: Bad username or password for https://bart_simpson@rubygems.pkg.github.com/private_org/.
remote: Please double-check your credentials and correct them.
remote: Bundler Output: Fetching gem metadata from https://rubygems.org/.......
remote: Fetching gem metadata from https://rubygems.pkg.github.com/private_org/.
remote:
remote:
remote: Bad username or password for https://bart_simpson@rubygems.pkg.github.com/private_org/.
remote: Please double-check your credentials and correct them.
remote:
remote: !
remote: ! Failed to install gems via Bundler.
remote: !
remote: ! Push rejected, failed to compile Ruby app.
remote:
remote: ! Push failed
...
...
...
带有个人访问令牌的文件(我知道):
$ cat ~/.bundle/config
---
BUNDLE_RUBYGEMS__PKG__GITHUB__COM: "bart_simpson:ghp_nJabIP9JjPe7KOwgDrkiJextJggm114MZh7f"
BUNDLE_HTTPS://RUBYGEMS__PKG__GITHUB__COM/PRIVATE_ORG/: "bart_simpson:ghp_nJabIP9JjPe7KOwgDrkiJextJggm114MZh7f"
和
$ cat ~/.gem/credentials
---
:github: Bearer ghp_nJabIP9JjPe7KOwgDrkiJextJggm114MZh7f
和
$ cat ~/.gemrc
---
:backtrace: false
:bulk_threshold: 1000
:sources:
- https://rubygems.org/
- https://bart_simpson:ghp_nJabIP9JjPe7KOwgDrkiJextJggm114MZh7f@rubygems.pkg.github.com/private_org/
:update_sources: true
:verbose: true