-
Notifications
You must be signed in to change notification settings - Fork 1
62 lines (51 loc) · 1.59 KB
/
ci.yml
File metadata and controls
62 lines (51 loc) · 1.59 KB
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
name: CI
on:
pull_request:
branches: [main]
push:
branches: [main]
permissions:
contents: read
jobs:
lint:
name: Shellcheck
runs-on: ubuntu-24.04
steps:
- name: Checkout repository
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- name: Install mise
uses: jdx/mise-action@1648a7812b9aeae629881980618f079932869151 # v4.0.1
- name: Run shellcheck
run: mise run lint
test:
name: Bash Tests
runs-on: ubuntu-24.04
steps:
- name: Checkout repository
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- name: Install mise
uses: jdx/mise-action@1648a7812b9aeae629881980618f079932869151 # v4.0.1
- name: Run tests
run: mise run test
validate-action:
name: Validate Action Structure
runs-on: ubuntu-24.04
steps:
- name: Checkout repository
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- name: Verify all referenced scripts exist
run: |
grep -oP 'github\.action_path \}\}/\K[^ "]+' action.yml | while read -r script; do
if [[ ! -f "$script" ]]; then
echo "::error::Script referenced in action.yml does not exist: $script"
exit 1
fi
done
- name: Verify scripts are executable
run: |
find scripts/ -name '*.sh' | while read -r script; do
if [[ ! -x "$script" ]]; then
echo "::error::Script is not executable: $script"
exit 1
fi
done