tools: use commit title as PR title when creating release proposal

PR-URL: https://github.com/nodejs/node/pull/56165
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com>
Reviewed-By: Juan José Arboleda <soyjuanarbol@gmail.com>
pull/56329/head
Antoine du Hamel 2024-12-09 12:10:51 +01:00 committed by Ruy Adorno
parent 0e24eebf24
commit d6e1efcc59
No known key found for this signature in database
GPG Key ID: 97B01419BD92F80A
1 changed files with 2 additions and 2 deletions

View File

@ -29,7 +29,7 @@ git node release --prepare --skipBranchDiff --yes --releaseDate "$RELEASE_DATE"
HEAD_BRANCH="$(git rev-parse --abbrev-ref HEAD)"
HEAD_SHA="$(git rev-parse HEAD^)"
TITLE=$(awk "/^## ${RELEASE_DATE}/ { print substr(\$0, 4) }" "doc/changelogs/CHANGELOG_V${RELEASE_LINE}.md")
TITLE="$(git log -1 --format=%s)"
# Use a temporary file for the PR body
TEMP_BODY="$(awk "/## ${RELEASE_DATE}/,/^<a id=/{ if (!/^<a id=/) print }" "doc/changelogs/CHANGELOG_V${RELEASE_LINE}.md")"
@ -56,7 +56,7 @@ node --input-type=module - \
"$GITHUB_REPOSITORY" \
"$HEAD_BRANCH" \
"$HEAD_SHA" \
"$(git log -1 HEAD --format=%s || true)" \
"$TITLE" \
"$(git log -1 HEAD --format=%b | awk -v PR_URL="$PR_URL" '{sub(/^PR-URL: TODO$/, "PR-URL: " PR_URL)} 1' || true)" \
"$(git show HEAD --diff-filter=d --name-only --format= || true)" \
"$(git show HEAD --diff-filter=D --name-only --format= || true)" \