github-push-action: Prompt "remote: Invalid username or password." when entering the"Push"line operation
我在一个组织仓库进行push操作的出现“remote: Invalid username or password.” error,我不知道怎么办
error截图: 我确定仓库URL没有任何的问题,这是我Actions的部分代码:
GitPushAndRelease:
needs: build
runs-on: ubuntu-latest
environment:
name: Update
steps:
- name: Commit
id: commit
run: |
git config --global user.email xianyongjian080402@126.com
git config --global user.name xianyongjian080402-Bot
git status
git add .
git commit -m "[Bot]-[Update ZipFile]"
continue-on-error: true
- name: Push changes
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.BOTTOKEN }}
我在仓库环境(Update)中设置了环境秘密:
由于组织仓库无法打开这个选项,导致我只能使用自己的token
这个代码在我自己的仓库中没有问题,除了${{ secrets.GITHUB_TOKEN}}
不同以外,其他代码都是一样的,我不知道如何修复这个问题,希望得到支持,谢谢!🙏
About this issue
- Original URL
- State: closed
- Created a year ago
- Reactions: 1
- Comments: 28
Commits related to this issue
- + fix: https://github.com/ad-m/github-push-action/issues/150 — committed to jinek/AsyncLocalRegion by deleted user a year ago
- Update Update.yml https://github.com/ad-m/github-push-action/issues/150#issuecomment-1454707682 — committed to David-xian66/MinecraftAssetsFileGet by David-xian66 a year ago
- [Bot]-[Update ZipFile] — committed to David-xian66/MinecraftAssetsFileGet by xianyongjian08040202 a year ago
👍 👍 👍
OKKK! 我按照您的指示更改了配置文件后,又排查出了一个问题,现在可以正常提交了,感谢!
在 https://github.com/SkyWorldStudio/MinecraftAssetsFileGet/commit/f7a4182f1cf07f1ada03f43851c5d07282cf54d2 中无法正常提交的原因貌似因为是错误的使用了
actions/checkout@v3
签出了存储库,这个操作删除了.git文件,导致git commit失败