Skip to content

Commit

Permalink
Merge pull request #20460 from mpherman2/other_bumper_fix
Browse files Browse the repository at this point in the history
Fix bash script autobumper to use new branch based EnsurePR
  • Loading branch information
k8s-ci-robot authored Jan 13, 2021
2 parents c6d9cf6 + 37a45bb commit ff516b7
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion hack/autodeps.sh
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ echo "Creating PR to merge ${user}:autoupdate into master..." >&2
bazel run //robots/pr-creator -- \
--github-token-path="${token}" \
--org=kubernetes --repo=test-infra --branch=master \
--title="${title}" --match-title="${title}" \
--title="${title}" --head-branch="autoupdate" \
--body="Automatic go module update. Please review" \
--source="${user}":autoupdate \
--confirm
2 changes: 1 addition & 1 deletion prow/cmd/autobump/autobump.sh
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ create-gh-pr() {
/pr-creator \
--github-token-path="${token}" \
--org="${GH_ORG}" --repo="${GH_REPO}" --branch=master \
--title="${title}" --match-title="Bump ${PROW_INSTANCE_NAME} from" \
--title="${title}" --head-branch="autobump-${PROW_INSTANCE_NAME}" \
--body="${body}" \
--source="${user}:autobump-${PROW_INSTANCE_NAME}" \
--confirm
Expand Down
6 changes: 3 additions & 3 deletions robots/pr-creator/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ type options struct {
source string

title string
matchTitle string
headBranch string
body string
}

Expand Down Expand Up @@ -78,7 +78,7 @@ func optionsFromFlags() options {
fs.BoolVar(&o.confirm, "confirm", false, "Set to mutate github instead of a dry run")
fs.BoolVar(&o.local, "local", false, "Allow source to be local-branch instead of remote-user:branch")
fs.StringVar(&o.title, "title", "", "Title of PR")
fs.StringVar(&o.matchTitle, "match-title", "", "Reuse any self-authored, open PR matching title")
fs.StringVar(&o.headBranch, "head-branch", "", "Reuse any self-authored open PR from this branch")
fs.StringVar(&o.body, "body", "", "Body of PR")
fs.Parse(os.Args[1:])
return o
Expand All @@ -100,7 +100,7 @@ func main() {
logrus.WithError(err).Fatal("Failed to create github client")
}

n, err := updater.EnsurePR(o.org, o.repo, o.title, o.body, o.source, o.branch, o.matchTitle, o.allowMods, gc)
n, err := updater.EnsurePR(o.org, o.repo, o.title, o.body, o.source, o.branch, o.headBranch, o.allowMods, gc)
if err != nil {
logrus.WithError(err).Fatal("Failed to ensure PR exists.")
}
Expand Down
2 changes: 1 addition & 1 deletion testgrid/cmd/transfigure/transfigure.sh
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ main() {
/pr-creator \
--github-token-path="${token}" \
--org="kubernetes" --repo="test-infra" --branch=master \
--title="${title}" --match-title="${title}" \
--title="${title}" --head-branch="${branch}" \
--body="Generated by transfigure.sh" \
--source="${user}:${branch}" \
--confirm
Expand Down

0 comments on commit ff516b7

Please sign in to comment.