Skip to content

Commit 932853c

Browse files
committed
New Makefile command
1 parent 317da40 commit 932853c

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

Makefile

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -354,6 +354,21 @@ else
354354
$(ALL_DONE)
355355
endif
356356
357+
php-parallel-lint: ## Lint PHP files with `php-parallel-lint`
358+
php-parallel-lint: info_msg := @printf $(_TITLE) "OK" "php-parallel-lint"
359+
php-parallel-lint: info
360+
ifeq ($(INSIDE_DOCKER_CONTAINER), 1)
361+
@./vendor/bin/parallel-lint --exclude .git --exclude app --exclude tools --exclude var --exclude vendor --colors --show-deprecated --blame .
362+
else ifeq ($(RUNNING_SOME_CONTAINERS), 0)
363+
$(WARNING_DOCKER)
364+
else ifneq ($(RUNNING_ALL_CONTAINERS), 1)
365+
$(ERROR_DOCKER)
366+
else
367+
$(NOTICE_HOST)
368+
@HOST_UID=$(HOST_UID) HOST_GID=$(HOST_GID) docker compose exec php make php-parallel-lint
369+
$(ALL_DONE)
370+
endif
371+
357372
psalm: ## Runs Psalm static analysis tool
358373
psalm: info_msg := @printf $(_TITLE) "OK" "Running Psalm - A static analysis tool for PHP"
359374
psalm: info

0 commit comments

Comments
 (0)