Fetch less and use the right SHA (#5621)

This commit is contained in:
Jack Amadeo
2025-11-07 06:25:07 -08:00
committed by GitHub
parent 4244dc924b
commit e6af4f5d12
3 changed files with 5 additions and 3 deletions
@@ -29,7 +29,7 @@ runs:
PRIOR_REF: ${{ inputs.prior_ref }}
TEMPLATE_FILE: "${{ github.action_path }}/pr_body_template.txt"
run: |
git fetch origin --tags
git fetch origin "$HEAD_REF" "$PRIOR_REF"
{
sed -e "s/{{VERSION}}/${VERSION}/g" \
+3 -1
View File
@@ -58,7 +58,9 @@ jobs:
just prepare-release $VERSION
BRANCH_NAME=$(git branch --show-current)
HEAD_REF=$(git rev-parse HEAD)
echo "branch_name=$BRANCH_NAME" >> $GITHUB_ENV
echo "head_ref=$HEAD_REF" >> $GITHUB_ENV
echo "Branch: $BRANCH_NAME"
- name: push release branch
@@ -69,7 +71,7 @@ jobs:
uses: ./.github/actions/generate-release-pr-body
with:
version: ${{ env.version }}
head_ref: ${{ github.event.pull_request.head.sha || github.sha }}
head_ref: ${{ env.head_ref }}
prior_ref: ${{ env.prior_ref }}
- name: Create Pull Request
@@ -114,7 +114,7 @@ jobs:
env:
BRANCH: ${{ steps.version.outputs.branch }}
run: |
git fetch origin
git fetch origin "$BRANCH"
BRANCH_SHA=$(git rev-parse "origin/$BRANCH")
echo "branch_sha=$BRANCH_SHA" >> $GITHUB_OUTPUT