Skip to content

Commit

Permalink
Enable shellcheck and fix warnings (heroku#123)
Browse files Browse the repository at this point in the history
  • Loading branch information
colincasey authored and Frzk committed May 13, 2024
1 parent 35d00ed commit 187bf6b
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 1 deletion.
9 changes: 9 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,3 +23,12 @@ jobs:
uses: actions/checkout@v4
- name: Functional tests on heroku:${{ matrix.stack_number }}-build
run: test/run

shell-lint:
runs-on: ubuntu-22.04
container:
image: koalaman/shellcheck-alpine:v0.9.0
steps:
- uses: actions/checkout@v4
- name: shellcheck
run: shellcheck -x bin/compile bin/detect bin/release bin/report
3 changes: 3 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
test: heroku-22-build heroku-20-build

shellcheck:
@shellcheck -x bin/compile bin/detect bin/release bin/report

heroku-22-build:
@echo "Running tests in docker (heroku-22-build)..."
@docker run -v $(shell pwd):/buildpack:ro --rm -it -e "STACK=heroku-22" heroku/heroku:22-build bash -c 'cp -r /buildpack /buildpack_test; cd /buildpack_test/; test/run;'
Expand Down
2 changes: 1 addition & 1 deletion bin/compile
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ for PACKAGE in $(cat $BUILD_DIR/$APT_FILE_MANIFEST | grep -v -s -e '^#' | grep -
topic "Fetching .debs for $PACKAGE"
apt-get "${APT_OPTIONS[@]}" -y "${APT_FORCE_YES[@]}" -d install --reinstall "$PACKAGE" | indent
fi
done
done < <(grep --invert-match -e "^#" -e "^\s*$" -e "^:repo:" "${BUILD_DIR}/Aptfile")

mkdir -p "$BUILD_DIR/.apt"

Expand Down

0 comments on commit 187bf6b

Please sign in to comment.