Run shellcheck on Travis CI
This commit is contained in:
parent
45a1989a1f
commit
b91a39be22
@ -52,6 +52,9 @@ matrix:
|
||||
language: node_js
|
||||
python: null
|
||||
node_js: "lts/*"
|
||||
- os: linux
|
||||
env: TESTENV=shellcheck
|
||||
services: docker
|
||||
fast_finish: true
|
||||
|
||||
cache:
|
||||
|
@ -14,6 +14,16 @@ elif [[ $TESTENV == eslint ]]; then
|
||||
# travis env
|
||||
cd qutebrowser/javascript || exit 1
|
||||
eslint --color --report-unused-disable-directives .
|
||||
elif [[ $TESTENV == shellcheck ]]; then
|
||||
dev_scripts=$( find scripts/dev/ -name '*.sh' -print0 | xargs -0 )
|
||||
# false positive: we are using 'find -exec +'
|
||||
# shellcheck disable=SC2038
|
||||
userscripts=$( find misc/userscripts/ -type f -exec grep -lE '[/ ][bd]ash$|[/ ]sh$|[/ ]ksh$' {} + | xargs )
|
||||
IFS=" " read -r -a scripts <<< "$dev_scripts $userscripts"
|
||||
docker run \
|
||||
-v "$PWD:/outside" \
|
||||
-w /outside \
|
||||
koalaman/shellcheck:stable "${scripts[@]}"
|
||||
else
|
||||
args=()
|
||||
[[ $TRAVIS_OS_NAME == osx ]] && args=('--qute-bdd-webengine' '--no-xvfb')
|
||||
|
Loading…
Reference in New Issue
Block a user