diff --git a/.docker/scripts/lint-theme b/.docker/scripts/lint-theme index 481fed80c..2e8d2c679 100644 --- a/.docker/scripts/lint-theme +++ b/.docker/scripts/lint-theme @@ -1,11 +1,12 @@ #!/usr/bin/env bash # Code linting for SaaS project. +set -e APP_DIR=${APP_DIR:-/app} PROFILE_DIR=${PROFILE_DIR:-${APP_DIR}/web} # Lint code. -${APP_DIR}/tests/vendor/bin/parallel-lint --exclude /app/tests/vendor -e php,inc,module,theme,install,profile,test ${PROFILE_DIR}/themes/custom +${APP_DIR}/tests/vendor/bin/parallel-lint --exclude /app/tests/vendor --exclude ${PROFILE_DIR}/themes/custom/*/node_modules -e php,inc,module,theme,install,profile,test ${PROFILE_DIR}/themes/custom # Check code standards. ${APP_DIR}/tests/vendor/bin/phpcs --standard=${APP_DIR}/tests/phpcs.xml ${PROFILE_DIR}/themes/custom diff --git a/tests/phpcs.xml b/tests/phpcs.xml index 9e926065b..49ad5d5ca 100755 --- a/tests/phpcs.xml +++ b/tests/phpcs.xml @@ -1,6 +1,6 @@ - - PHPCS Standard for a GoVCMS8 website, based on Drupal standards. + + PHPCS Standard for a GovCMS8 website, based on Drupal standards. @@ -24,6 +24,9 @@ *library*\.js *libraries*\.js + + web/themes/custom/*/node_modules/* + *\.bean\.* *\.context\.*