github-push-action
github-push-action copied to clipboard
Does not work for private repositories
When trying to push to a private repository (the same repo that the action is run from), I get a "fatal: repository 'https://github.com/
it works for me for private repos with the GITHUB TOKEN so you must have something set up incorrectly.
I'm trying it from a private repo in a privae org. That might the case. Nevertheless, I managed to work around, so if nobody else encounters this, I'm ok with closing.
@e8johan How did you solve this? I've tried quite a few ways and still badly stuck with this
@e8johan could you please share the workaround you mentioned?
Hi everyone, I fixed this in our repositories by removing the step and replacing it with:
- name: Push Commit
run: git push https://${{ secrets.GITHUB_PAT }}@github.com/<REPO_OWNER>/<REPO_NAME>.git
The repo owner is our organisation and the GITHUB_PAT is a personal access token. Hope this helps! 😉
Chances are you'r using actions/checkout@v2 already. It offers a solution to push a commit using the built-in token.
I'm having the same issue as @e8johan. and am using this action in combination with jaumann/[email protected] Hope someone can shed some light on this issue because i'm stuck.
Hi everyone, I fixed this in our repositories by removing the step and replacing it with:
- name: Push Commit run: git push https://${{ secrets.GITHUB_PAT }}@github.com/<REPO_OWNER>/<REPO_NAME>.git
The repo owner is our organisation and the GITHUB_PAT is a personal access token. Hope this helps! 😉
How to make the owner dynamically to the the PR maker?