mirror of https://github.com/FriendsOfTYPO3/tea.git synced 2024-12-23 03:46:11 +01:00

[TASK] Add lint stage in gitlab ci (#82)

This commit is contained in:
Łukasz Uznański 2020-09-05 12:37:50 +02:00 committed by GitHub
parent 11e27d01ae
commit f812769c15
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 57 additions and 2 deletions

View file

@ -2,6 +2,7 @@
stages:
- build
- code_quality
- lint
- test
include:
@ -16,6 +17,7 @@ default:
build-composer-dependencies:
stage: build
needs: []
variables:
COMPOSER_CACHE_DIR: '.composer'
script:
@ -33,9 +35,62 @@ build-composer-dependencies:
phpcs:
stage: code_quality
needs:
- build-composer-dependencies
script:
- composer ci:php:sniff
php-lint-php7.2:
image: php:7.2
stage: lint
needs: []
script:
- composer ci:php:lint
php-lint-php7.3:
image: php:7.3
stage: lint
needs: []
script:
- composer ci:php:lint
php-lint-php7.4:
image: php:7.4
stage: lint
needs: []
script:
- composer ci:php:lint
ts-lint:
stage: lint
needs:
- build-composer-dependencies
script:
- composer ci:ts:lint
json-lint:
stage: lint
needs:
- build-composer-dependencies
script:
- composer ci:json:lint
yaml-lint:
stage: lint
needs:
- build-composer-dependencies
script:
- composer ci:yaml:lint
xliff-lint:
stage: lint
needs:
- build-composer-dependencies
script:
- wget https://docs.oasis-open.org/xliff/v1.2/os/xliff-core-1.2-strict.xsd
- xmllint --schema ./xliff-core-1.2-strict.xsd
--noout $(find Resources -name '*.xlf')
code_quality:
before_script: []

View file

@ -5,9 +5,9 @@
set -xe
apt-get update -yqq
apt-get install git libzip-dev unzip -yqq
apt-get install git libzip-dev unzip libxml2-utils wget -yqq
php -r "readfile('http://getcomposer.org/installer');" | php -- --install-dir=/usr/local/bin/ --filename=composer
chmod +x /usr/local/bin/composer
docker-php-ext-install zip
docker-php-ext-install zip