Skip to content

Commit 989685b

Browse files
committed
Modernize Makefile with rollerscapes/standards
Use the base Makefile of the rollerscapes/standards package
1 parent 1f19f95 commit 989685b

2 files changed

Lines changed: 5 additions & 27 deletions

File tree

.github/workflows/ci.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ jobs:
5050

5151
-
5252
name: 'Check the code style'
53-
run: 'make cs-full'
53+
run: 'make cs'
5454

5555
phpstan:
5656
name: 'PhpStan'

Makefile

Lines changed: 4 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,7 @@
1-
QA_DOCKER_IMAGE=jakzal/phpqa:1.92.1-php8.2-alpine
2-
QA_DOCKER_COMMAND=docker run --init -t --rm --user "$(shell id -u):$(shell id -g)" --volume /tmp/tmp-phpqa-$(shell id -u):/tmp --volume "$(shell pwd):/project" --workdir /project ${QA_DOCKER_IMAGE}
1+
include vendor/rollerscapes/standards/Makefile
32

4-
dist: install cs-full phpstan test-full
5-
lint: install cs-full phpstan
3+
QA_DOCKER_IMAGE=jakzal/phpqa:1.115.0-php8.4-alpine
64

7-
install:
8-
composer install --no-progress --no-interaction --no-suggest --optimize-autoloader --prefer-dist --ansi
5+
phpunit:
6+
./vendor/bin/phpunit
97

10-
test:
11-
vendor/bin/phpunit
12-
13-
# Linting tools
14-
phpstan: ensure
15-
vendor/bin/phpstan analyse
16-
17-
cs: ensure
18-
sh -c "${QA_DOCKER_COMMAND} php-cs-fixer fix -vvv --diff"
19-
20-
cs-full: ensure
21-
sh -c "${QA_DOCKER_COMMAND} php-cs-fixer fix -vvv --using-cache=no --diff"
22-
23-
cs-full-check: ensure
24-
sh -c "${QA_DOCKER_COMMAND} php-cs-fixer fix -vvv --using-cache=no --diff --dry-run"
25-
26-
ensure:
27-
mkdir -p ${HOME}/.composer /tmp/tmp-phpqa-$(shell id -u)
28-
29-
.PHONY: install test phpstan cs cs-full cs-full-check

0 commit comments

Comments
 (0)