44 workflow_run :
55 workflows :
66 - Test
7- - Smoke Test (PR)
7+ - Build Preview CLI Packages
88 types :
99 - completed
1010
3939 should_publish=false
4040 pr_number=""
4141 pr_head_sha=""
42- smoke_run_id =""
42+ preview_build_run_id =""
4343 test_run_id=""
4444
4545 pr_number="$(jq -r '.workflow_run.pull_requests[0].number // ""' "$GITHUB_EVENT_PATH")"
7070 exit 0
7171 fi
7272
73- if [[ "${triggering_workflow}" == "Smoke Test (PR) " ]]; then
74- smoke_run_id ="$(jq -r '.workflow_run.id' "$GITHUB_EVENT_PATH")"
73+ if [[ "${triggering_workflow}" == "Build Preview CLI Packages " ]]; then
74+ preview_build_run_id ="$(jq -r '.workflow_run.id' "$GITHUB_EVENT_PATH")"
7575 elif [[ "${triggering_workflow}" == "Test" ]]; then
7676 test_run_id="$(jq -r '.workflow_run.id' "$GITHUB_EVENT_PATH")"
7777 else
@@ -111,10 +111,10 @@ jobs:
111111 exit 0
112112 fi
113113
114- if [[ -z "${smoke_run_id }" ]]; then
115- smoke_run_id ="$(
114+ if [[ -z "${preview_build_run_id }" ]]; then
115+ preview_build_run_id ="$(
116116 gh run list \
117- --workflow smoke-test-pr .yml \
117+ --workflow build-preview-cli-packages .yml \
118118 --event pull_request \
119119 --commit "${pr_head_sha}" \
120120 --status success \
@@ -135,8 +135,8 @@ jobs:
135135 )"
136136 fi
137137
138- if [[ -z "${smoke_run_id }" ]]; then
139- echo "No successful Smoke Test (PR) run found for ${pr_head_sha}; skipping."
138+ if [[ -z "${preview_build_run_id }" ]]; then
139+ echo "No successful Build Preview CLI Packages run found for ${pr_head_sha}; skipping."
140140 echo "should_publish=false" >> "$GITHUB_OUTPUT"
141141 exit 0
142142 fi
@@ -148,14 +148,14 @@ jobs:
148148 fi
149149
150150 artifact_name="$(
151- gh api "repos/${REPOSITORY}/actions/runs/${smoke_run_id }/artifacts" \
151+ gh api "repos/${REPOSITORY}/actions/runs/${preview_build_run_id }/artifacts" \
152152 --paginate \
153153 --jq '.artifacts[] | select(.name | startswith("cli-build-legacy-")) | .name' \
154154 | head -n 1
155155 )"
156156
157157 if [[ -z "${artifact_name}" ]]; then
158- echo "No legacy CLI build artifact found on Smoke Test (PR) run ${smoke_run_id }; skipping."
158+ echo "No legacy CLI build artifact found on Build Preview CLI Packages run ${preview_build_run_id }; skipping."
159159 echo "should_publish=false" >> "$GITHUB_OUTPUT"
160160 exit 0
161161 fi
@@ -169,7 +169,7 @@ jobs:
169169 echo "pr_head_sha=${pr_head_sha}"
170170 echo "preview_version=${preview_version}"
171171 echo "artifact_name=${artifact_name}"
172- echo "smoke_run_id =${smoke_run_id }"
172+ echo "preview_build_run_id =${preview_build_run_id }"
173173 } >> "$GITHUB_OUTPUT"
174174
175175 - name : Checkout
@@ -183,12 +183,12 @@ jobs:
183183 if : steps.context.outputs.should_publish == 'true'
184184 uses : ./.github/actions/setup
185185
186- - name : Download smoke artifacts
186+ - name : Download preview build artifacts
187187 if : steps.context.outputs.should_publish == 'true'
188- run : gh run download "${SMOKE_RUN_ID }" --name "${ARTIFACT_NAME}"
188+ run : gh run download "${PREVIEW_BUILD_RUN_ID }" --name "${ARTIFACT_NAME}"
189189 env :
190190 ARTIFACT_NAME : ${{ steps.context.outputs.artifact_name }}
191- SMOKE_RUN_ID : ${{ steps.context.outputs.smoke_run_id }}
191+ PREVIEW_BUILD_RUN_ID : ${{ steps.context.outputs.preview_build_run_id }}
192192
193193 - name : Prepare package files
194194 if : steps.context.outputs.should_publish == 'true'
@@ -245,7 +245,7 @@ jobs:
245245 ${marker}
246246 ## pkg.pr.new preview
247247
248- Published version \`${PREVIEW_VERSION}\` from commit [\`${short_sha}\`](https://github.com/${REPOSITORY}/commit/${PR_HEAD_SHA}) after the PR test and release smoke workflows passed.
248+ Published version \`${PREVIEW_VERSION}\` from commit [\`${short_sha}\`](https://github.com/${REPOSITORY}/commit/${PR_HEAD_SHA}) after the PR test and preview build workflows passed.
249249
250250 \`\`\`sh
251251 npx ${preview_url}
0 commit comments