-
Notifications
You must be signed in to change notification settings - Fork 0
36 lines (31 loc) · 886 Bytes
/
Copy pathshellcheck.yml
File metadata and controls
36 lines (31 loc) · 886 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
name: Shellcheck runner
# Lint the campaign-runner shell scripts. This is a static gate only — the
# runner is exercised for real on the benchmark devbox, not in CI.
on:
push:
branches: [main]
paths:
- "runner/**"
- ".github/workflows/shellcheck.yml"
pull_request:
paths:
- "runner/**"
- ".github/workflows/shellcheck.yml"
permissions:
contents: read
jobs:
shellcheck:
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v4
- name: Syntax-check (bash -n)
run: |
for f in runner/*.sh; do
echo "bash -n $f"
bash -n "$f"
done
- name: Shellcheck
# The .cfg is a sourced bash fragment and carries its own
# `shellcheck shell=bash` directive, so it lints too.
run: shellcheck runner/*.sh runner/*.cfg