Skip to content

fix: pass GitHub event context via env vars in reusable workflow#20

Merged
epmog merged 1 commit into
mainlinefrom
fix/pr-details-env-vars
Jul 7, 2026
Merged

fix: pass GitHub event context via env vars in reusable workflow#20
epmog merged 1 commit into
mainlinefrom
fix/pr-details-env-vars

Conversation

@crowecawcaw

Copy link
Copy Markdown

What was the problem/requirement? (What/Why)

The Record PR Details reusable workflow interpolated github.event.* values directly into an inline run: script.

What was the solution? (How)

Move the github.event.* values (pull_request.number, event.action) out of the inline run: script and into an env: block, so they are referenced as shell variables rather than templated into the script text.

What is the impact of this change?

No behavioral change — the artifact contents are identical. This is a small workflow-hygiene cleanup that keeps the pattern consistent with the other reusable workflows (e.g. responded.yml) and with the equivalent workflow in aws-deadline/.github (aws-deadline#87).

How was this change tested?

YAML validated locally. The values consumed are unchanged; only how they are passed to the shell differs.

Was this change documented?

n/a

Is this a breaking change?

No

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

Move github.event.* interpolations (pull_request.number, event.action)
out of the inline run: script and into an env: block so they are
referenced as shell variables rather than templated into script text.

These values are GitHub-controlled and structurally constrained, so this
is a defense-in-depth cleanup that also keeps CI/scanner patterns happy.

Signed-off-by: Stephen Crowe <6042774+crowecawcaw@users.noreply.github.com>
@crowecawcaw
crowecawcaw requested a review from a team as a code owner July 7, 2026 02:43
@epmog
epmog merged commit 0931251 into mainline Jul 7, 2026
4 checks passed
@epmog
epmog deleted the fix/pr-details-env-vars branch July 7, 2026 15:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants