-
Notifications
You must be signed in to change notification settings - Fork 14
34 lines (32 loc) · 983 Bytes
/
ci.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
---
name: CI
on:
push:
branches: [master]
pull_request:
branches: [master]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/cache@v3
id: cache-shellcheck
with:
path: bin/shellcheck
key: ${{ runner.os }}-shellcheck
restore-keys: |
${{ runner.os }}-shellcheck
- name: Setup bin directories
run: |
mkdir -p "$(pwd)/bin"
export PATH=$(pwd)/bin:$HOME/.local/bin:$PATH
- name: Get shellcheck binary
if: steps.cache-shellcheck.outputs.cache-hit != 'true'
run: |
wget -qO- https://github.com/koalaman/shellcheck/releases/download/stable/shellcheck-stable.linux.x86_64.tar.xz | tar -xJv
mv "shellcheck-stable/shellcheck" "$(pwd)/bin/shellcheck"
chmod +x "$(pwd)/bin/shellcheck"
- name: Run test and shellcheck
run: |
timeout 10m make test shellcheck