Closed marshall7m closed 2 years ago
Hi @marshall7m ,
It looks like you already have a master branch for the marshall7m/terraform-aws-github-ci
repo. If you re-run your command while passing the --loglevel debug
flag you will see the more verbose error message at runtime:
git-xargs --loglevel debug --repo zack-test-org/terraform-aws-eks --branch-name master --commit-message "add blank file" --skip-pull-requests touch foo.txt
Total 195 (delta 159), reused 27 (delta 11), pack-reused 17 Repo=terraform-aws-eks
[git-xargs] DEBU[2021-06-29T12:11:31-04:00] Created branch Branc
h Name=refs/heads/master Repo=terraform-aws-eks
[git-xargs] DEBU[2021-06-29T12:11:31-04:00] Error creating new branch Error
="a branch named \"refs/heads/master\" already exists" Repo=terraform-aws-eks
[git-xargs] DEBU[2021-06-29T12:11:31-04:00] Error encountered while processing repo Error
="a branch named \"refs/heads/master\" already exists" Repo name=terraform-aws-eks
Could you please try again while passing the name of a new branch for git-xargs
to create?
I'm going to close this issue out due to inactivity and inability to reproduce, but please feel free to re-open if I've misunderstood the problem. Thanks!
I have the same problem as @marshall7m I am trying to push changes directly to the existing master branch, but git-xargs shows an error that this branch already exists.
The readme suggest that it is possible to provide a branch that already exists for the --branch-name argument. "If you specify the name of a branch that exists on your remote, its latest changes will be pulled locally prior to your command or script being run." https://github.com/gruntwork-io/git-xargs#branch-behavior
This would be very useful if it worked correctly, because if you have a lot of repositories and use git-xargs you still have to accept all the pull requests manually.
git-xargs version What does
git-xargs --version
show?v0.0.10
Describe the bug A clear and concise description of what the bug is. I'm trying to push a blank file viagit-xargs
on a repository that I own.To Reproduce Steps to reproduce the behavior:
export GITHUB_OAUTH_TOKEN=xxx
Expected behavior A clear and concise description of what you expected to happen.
Expected
foo.txt
to be pushed to target repo's master branch Additional context Add any other context about the problem here.