-
Notifications
You must be signed in to change notification settings - Fork 0
43 lines (39 loc) · 1.12 KB
/
test.yml
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
name: Test commit-status-action
on:
pull_request:
branches: [master]
push:
branches: [master]
jobs:
create_status:
runs-on: ubuntu-latest
outputs:
sha: ${{ steps.commit_status.outputs.commit_status_sha }}
steps:
- uses: actions/checkout@v4
- name: Create pending status
id: commit_status
uses: ./create
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
shellcheck:
# Use newer os for more up-to-date shellcheck
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Run shellcheck on .sh and .bash files files
run: |
find . -name '*.sh' -exec shellcheck -s bash '{}' \+
find . -name '*.bash' -exec shellcheck -s bash '{}' \+
finalize_status:
runs-on: ubuntu-latest
needs: [shellcheck, create_status]
if: ${{ always() }}
steps:
- uses: actions/checkout@v4
- name: Update commit status
uses: ./update
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
github-needs: ${{ toJson(needs) }}
sha: ${{ needs.create_status.outputs.sha }}