build-configs(update)
This commit is contained in:
parent
03e0977a88
commit
9ea05ff9aa
1 changed files with 3 additions and 20 deletions
23
run
23
run
|
|
@ -2,7 +2,8 @@
|
|||
|
||||
# Do not edit this file. It is automatically generated by https://www.oliverdavies.uk/build-configs.
|
||||
|
||||
set -eu
|
||||
set -o errexit
|
||||
set -o pipefail
|
||||
|
||||
# Run automated tests as part of the Continuous Integration (CI) pipeline.
|
||||
function ci:test {
|
||||
|
|
@ -21,9 +22,7 @@ function ci:test {
|
|||
|
||||
composer install --quiet --no-progress
|
||||
|
||||
test --testdox
|
||||
|
||||
quality
|
||||
}
|
||||
|
||||
# Run a command within the php container.
|
||||
|
|
@ -31,9 +30,6 @@ function cmd {
|
|||
docker compose exec php "${@}"
|
||||
}
|
||||
|
||||
function coding-standards {
|
||||
cmd phpcs "${@}"
|
||||
}
|
||||
|
||||
function composer {
|
||||
_exec php composer "${@}"
|
||||
|
|
@ -65,10 +61,6 @@ function lint:dockerfile {
|
|||
hadolint/hadolint hadolint --ignore DL3008 --ignore DL3059 -t style "${@}" - < Dockerfile
|
||||
}
|
||||
|
||||
function quality {
|
||||
coding-standards
|
||||
static-analysis
|
||||
}
|
||||
|
||||
function start {
|
||||
cp -v --no-clobber .env.example .env
|
||||
|
|
@ -76,22 +68,13 @@ function start {
|
|||
docker compose up -d
|
||||
}
|
||||
|
||||
function static-analysis {
|
||||
cmd phpstan --memory-limit=-1 --no-progress "${@}"
|
||||
}
|
||||
|
||||
function stop {
|
||||
docker compose down
|
||||
}
|
||||
|
||||
function test {
|
||||
_exec php phpunit --colors=always "${@}"
|
||||
}
|
||||
|
||||
function test:commit {
|
||||
test --testdox --testsuite functional
|
||||
test --testdox --testsuite kernel
|
||||
test --testdox --testsuite unit
|
||||
|
||||
quality
|
||||
}
|
||||
|
|
@ -113,7 +96,7 @@ function _run {
|
|||
}
|
||||
|
||||
# Include any local tasks.
|
||||
source run.local || true
|
||||
[[ -e run.local ]] && source run.local
|
||||
|
||||
TIMEFORMAT=$'\nTask completed in %3lR'
|
||||
time "${@:-help}"
|
||||
|
|
|
|||
Reference in a new issue