-
Notifications
You must be signed in to change notification settings - Fork 71
63 lines (54 loc) · 1.55 KB
/
scandir.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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
name: 'scandir'
on:
push:
branches:
- "master"
pull_request:
branches:
- "master"
permissions: {}
jobs:
scandir:
name: scandir
runs-on: ${{ matrix.os }}
strategy:
matrix:
os:
- ubuntu-latest
- macos-latest
steps:
- name: Checkout
uses: actions/[email protected]
- name: Run ShellCheck
uses: ./
id: one
with:
scandir: testfiles/scandir
- name: Verify check
run: |
expect="testfiles/scandir/run[[:space:]]me.bash"
notexpect="testfiles/test.bash"
if [[ ! "${{ steps.one.outputs.files }}" =~ $expect ]];then
echo "::error:: Expected file $expect not found in ${{ steps.one.outputs.files }}"
exit 1
elif [[ "${{ steps.one.outputs.files }}" =~ $notexpect ]];then
echo "::error:: Expected file $notexpect found in ${{ steps.one.outputs.files }}"
exit 1
fi
- name: Run ShellCheck
uses: ./
id: two
with:
scandir: './testfiles/scandir'
ignore_paths: ignore
- name: Verify check
run: |
expect="testfiles/scandir/test.bash"
notexpect="testfiles/test.bash"
if [[ ! "${{ steps.two.outputs.files }}" =~ $expect ]];then
echo "::error:: Expected file $expect not found in ${{ steps.two.outputs.files }}"
exit 1
elif [[ "${{ steps.two.outputs.files }}" =~ $notexpect ]];then
echo "::error:: Expected file $notexpect found in ${{ steps.two.outputs.files }}"
exit 1
fi