From 9dd92835ab6e969be29bf968e4f71bf034e24c60 Mon Sep 17 00:00:00 2001 From: Peter Evans <18365890+peter-evans@users.noreply.github.com> Date: Tue, 29 Nov 2022 15:08:37 +0900 Subject: [PATCH] push branch instead of head --- dist/index.js | 2 +- src/create-pull-request.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dist/index.js b/dist/index.js index c6d6fd1..57828d7 100644 --- a/dist/index.js +++ b/dist/index.js @@ -431,7 +431,7 @@ function createPullRequest(inputs) { yield git.push([ '--force-with-lease', branchRemoteName, - `HEAD:refs/heads/${inputs.branch}` + `${inputs.branch}:refs/heads/${inputs.branch}` ]); core.endGroup(); } diff --git a/src/create-pull-request.ts b/src/create-pull-request.ts index 3fa3ec2..83bf8bc 100644 --- a/src/create-pull-request.ts +++ b/src/create-pull-request.ts @@ -195,7 +195,7 @@ export async function createPullRequest(inputs: Inputs): Promise { await git.push([ '--force-with-lease', branchRemoteName, - `HEAD:refs/heads/${inputs.branch}` + `${inputs.branch}:refs/heads/${inputs.branch}` ]) core.endGroup() }