Skip to content
Snippets Groups Projects
Verified Commit 654ee531 authored by Bartek Jaskulski's avatar Bartek Jaskulski
Browse files

feat: switch to php-parallel-lint for linting

parent 737097f5
No related branches found
No related tags found
No related merge requests found
......@@ -6,17 +6,16 @@
- composer config gitlab-token.gitlab.wpdesk.dev gitlab-ci-token ${CI_JOB_TOKEN}
- composer install --no-dev
- rm auth.json
- phive install -g https://github.com/php-parallel-lint/PHP-Parallel-Lint/releases/download/v1.4.0/parallel-lint.phar --force-accept-unsigned
script:
- |
set -x; \
LINT="$(find . -name '*.php' -print0 |xargs -n1 -0 -P16 php -l 2>&1)"; \
RESULT="$?"; \
if [[ "$RESULT" -ne 0 ]]; then
echo -e "$LINT" | grep -v 'No syntax errors';
exit 0;
else
exit "$RESULT"
fi
- parallel-lint . --gitlab > lint-codequality.json || true
- parallel-lint .
artifacts:
paths:
- lint-codequality.json
expire_in: 1 week
reports:
codequality: lint-codequality.json
lint:8.3:
extends: .lint
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment