fix(ci): use shell var for jq --arg title in deploy steps (CAR-1436) #44
Reference in New Issue
Block a user
Delete Branch "car-1436-fix-deploy-jq-title"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
CAR-1436 — Fix bash syntax error in deploy-dev/deploy-uat PR body construction
Problem
The
--arg title (...)form in thejqcall uses GitHub-Actions expression syntax (env.GITHUB_SHA[:12]) inside a bashrun:block. The bare(opens a subshell →syntax error near unexpected token— the script dies in ~1s before the infra PR-creationcurlever executes.Fix
Extract title to a shell variable (
TITLE=) using the${GITHUB_SHA::12}bash slice syntax already used in thegit commit -mline two lines above, in BOTHdeploy-dev(line 145) anddeploy-uatsteps.Verification
After promotion to
uat, the deploy-uat step should pass jq construction and reach the infra PR-creation call (creating an infra PR with baseuat).cc @cpfarhood