-
Notifications
You must be signed in to change notification settings - Fork 6
/
composer.json
55 lines (55 loc) · 1.78 KB
/
composer.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
{
"autoload": {
"psr-4": {
"GravApi\\": "src/"
}
},
"require": {
"slim/slim": "^3.12"
},
"require-dev": {
"squizlabs/php_codesniffer": "^3.4",
"brainmaestro/composer-git-hooks": "^2.7",
"codeception/codeception": "^2.4",
"overtrue/phplint": "^1.1",
"getgrav/grav": "1.6.15",
"phpstan/phpstan": "^0.12.18"
},
"scripts": {
"docker:clean": [
"docker-compose -f docker-compose.yaml rm",
"docker rmi -f grav-api-dev"
],
"lint": [
"./vendor/bin/phpcs --colors --standard=PSR2 --encoding=utf-8 ./src api.php",
"./vendor/bin/phplint ./src --ansi --configuration=phplint.yaml"
],
"lint:fix": "./vendor/bin/phpcbf --colors --standard=PSR2 --encoding=utf-8 --basepath=$(pwd) ./src ./tests api.php",
"post-install-cmd": "vendor/bin/cghooks add --ignore-lock",
"post-update-cmd": "vendor/bin/cghooks update",
"stan": "vendor/bin/phpstan analyse src",
"start": "docker-compose -f docker-compose.yaml up -d",
"start:clean": [
"composer stop",
"composer docker:clean",
"composer start"
],
"stop": "docker-compose -f docker-compose.yaml down",
"test": [
"composer start",
"docker-compose exec -T --workdir /var/www/html grav ./user/plugins/api/vendor/bin/codecept -c ./user/plugins/api/ run unit"
],
"test:bootstrap": [
"composer start",
"docker-compose exec -T --workdir /var/www/html grav ./user/plugins/api/vendor/bin/codecept -c ./user/plugins/api/ bootstrap",
"docker-compose exec -T --workdir /var/www/html grav ./user/plugins/api/vendor/bin/codecept -c ./user/plugins/api/ build"
]
},
"extra": {
"hooks": {
"pre-commit": "composer lint",
"pre-push": "composer test",
"post-merge": "composer install"
}
}
}