From 6de6e25de1772fbaa197b87a32183933146d176d Mon Sep 17 00:00:00 2001 From: lucianposton Date: Thu, 2 Apr 2020 18:31:32 -0500 Subject: [PATCH] Add shellcheck to CI workflow (#33) --- .github/workflows/CI.yml | 32 ++++++++++++++++++++++++++++++++ .github/workflows/tests.yml | 17 ----------------- README.md | 3 +-- 3 files changed, 33 insertions(+), 19 deletions(-) create mode 100644 .github/workflows/CI.yml delete mode 100644 .github/workflows/tests.yml diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml new file mode 100644 index 0000000..c788675 --- /dev/null +++ b/.github/workflows/CI.yml @@ -0,0 +1,32 @@ +name: "CI" +on: [push, pull_request] +jobs: + shellcheck: + name: "Shellcheck" + runs-on: ubuntu-latest + steps: + - name: "Check out code" + uses: actions/checkout@v1 + + - name: "Run Shellcheck" + uses: azohra/shell-linter@v0.2.0 + + - name: "Run Shellcheck on BATS files" + uses: azohra/shell-linter@v0.2.0 + with: + path: "tests/*.bash,tests/*.bats" + + bats: + name: "BATS Tests" + runs-on: ubuntu-latest + steps: + - name: "Setup BATS testing framework" + uses: mig4/setup-bats@v1.0.1 + with: + bats-version: 1.1.0 + + - name: "Check out code" + uses: actions/checkout@v1 + + - name: "Run BATS tests" + run: bats -r tests diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml deleted file mode 100644 index f70ecd6..0000000 --- a/.github/workflows/tests.yml +++ /dev/null @@ -1,17 +0,0 @@ -name: "Tests" -on: [push, pull_request] -jobs: - bats: - name: "BATS job" - runs-on: ubuntu-latest - steps: - - name: "Setup BATS testing framework" - uses: mig4/setup-bats@v1.0.1 - with: - bats-version: 1.1.0 - - - name: "Check out code" - uses: actions/checkout@v1 - - - name: "Run BATS tests" - run: bats -r tests diff --git a/README.md b/README.md index 261fc8e..627a209 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,4 @@ -![Tests](https://github.com/TheChymera/mkstage4/workflows/Tests/badge.svg) -![Shellcheck](https://github.com/TheChymera/mkstage4/workflows/Shellcheck/badge.svg) +![CI](https://github.com/TheChymera/mkstage4/workflows/CI/badge.svg) # mkstage4