Skip to content

Commit

Permalink
Fix release commit and pr body error
Browse files Browse the repository at this point in the history
  • Loading branch information
pwtyler committed Dec 18, 2023
1 parent e41024c commit 8ab6222
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions .bin/release-pr.sh
Original file line number Diff line number Diff line change
Expand Up @@ -61,14 +61,16 @@ main() {
git config user.email "[email protected]"
git config user.name "Pantheon Automation"

RELEASE_MESSAGE="Release ${NEW_VERSION}. If CI tests have not run, close this PR and re-open it."
RELEASE_MESSAGE="Release ${NEW_VERSION}"
git commit -m "${RELEASE_MESSAGE}"
git push origin "${RELEASE_BRANCH}" --force

# Create a draft PR
if ! gh pr view "${RELEASE_BRANCH}"; then
local PR_TITLE="${RELEASE_MESSAGE}"
local PR_BODY="${RELEASE_MESSAGE}. If CI tests have not run, close this PR and re-open it."
gh pr create --draft --base "release" \
--title "${RELEASE_MESSAGE}" --body "${RELEASE_MESSAGE}." \
--title "${PR_TITLE}" --body "${RELEASE_BODY}" \
--label "automation"
fi
}
Expand Down

0 comments on commit 8ab6222

Please sign in to comment.