@@ -184,53 +184,25 @@ jobs:
184184 GH_TOKEN : ${{ github.token }}
185185 run : gh extension install github/gh-aw --pin v0.71.5
186186
187- - name : Determine workflows to compile
188- id : workflows
189- shell : bash
190- run : |
191- set -euo pipefail
192-
193- # Always compile all gh-aw workflows. The compiler is pinned via
194- # `gh extension install --pin` and `--no-check-update`, and action
195- # SHAs are pinned via .github/aw/actions-lock.json, so the output
196- # is deterministic for a given pinned version. Compiling all
197- # workflows takes only a couple of seconds.
198- mapfile -t workflow_ids < <(
199- find .github/workflows -maxdepth 1 -name "*.md" \
200- -exec basename {} .md \; \
201- | sort
202- )
203-
204- if [[ ${#workflow_ids[@]} -eq 0 ]]; then
205- echo "No gh-aw workflow sources found."
206- echo "workflows=" >> "$GITHUB_OUTPUT"
207- exit 0
208- fi
209-
210- echo "Workflows to compile:"
211- printf '%s\n' "${workflow_ids[@]}"
212-
213- {
214- echo "workflows<<EOF"
215- printf '%s ' "${workflow_ids[@]}"
216- echo
217- echo "EOF"
218- } >> "$GITHUB_OUTPUT"
187+ # Always compile all gh-aw workflows. The compiler is pinned via
188+ # `gh extension install --pin` and `--no-check-update`, and action
189+ # SHAs are pinned via .github/aw/actions-lock.json, so the output is
190+ # deterministic for a given pinned version. With no arguments, both
191+ # `gh aw validate` and `gh aw compile` operate on every Markdown file
192+ # in .github/workflows. Compiling all workflows takes only a couple
193+ # of seconds.
219194
220195 - name : Validate gh-aw workflows
221- if : steps.workflows.outputs.workflows != ''
222196 env :
223197 GH_TOKEN : ${{ github.token }}
224- run : gh aw validate ${{ steps.workflows.outputs.workflows }} --no-check-update
198+ run : gh aw validate --no-check-update
225199
226200 - name : Compile gh-aw workflows
227- if : steps.workflows.outputs.workflows != ''
228201 env :
229202 GH_TOKEN : ${{ github.token }}
230- run : gh aw compile ${{ steps.workflows.outputs.workflows }} --no-check-update
203+ run : gh aw compile --no-check-update
231204
232205 - name : Check generated files are committed
233- if : steps.workflows.outputs.workflows != ''
234206 run : |
235207 git diff --exit-code -- \
236208 .github/workflows \
0 commit comments