forked from extcode/cart_paypal
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.gitlab-ci.yml
109 lines (97 loc) · 2.94 KB
/
.gitlab-ci.yml
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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
cache:
key: "$CI_JOB_STAGE-$CI_COMMIT_REF_NAME"
paths:
- .composer/
- .php_cs.cache
variables:
COMPOSER_CACHE_DIR: ".composer"
before_script:
- apk add git --update
stages:
- lint
- documentation
- analysis
lint:cgl:
image: composer:2.0
stage: lint
before_script:
- composer config platform.php 7.4
- composer remove typo3/cms-core --no-update
- composer install --no-progress --no-ansi --no-interaction
script:
- .build/bin/php-cs-fixer fix --config=Build/.php-cs-fixer.dist.php -v --dry-run --using-cache=no --path-mode=intersection ./
lint:typoscriptcgl:
stage: lint
image: composer:2.0
script:
- composer config platform.php 7.4
- composer remove typo3/cms-core --no-update
- composer install --no-progress --no-ansi --no-interaction
- .build/bin/typoscript-lint -c tslint.yaml
lint:yaml:
stage: lint
image: python:alpine3.7
before_script:
- pip install yamllint==1.10.0
script:
- yamllint -c Build/yamllint.yaml Configuration/ Resources/ .travis.yml
lint:php72:
stage: lint
image: php:7.2-alpine
script:
- find . -name \*.php -exec php -l "{}" \;
lint:php73:
stage: lint
image: php:7.3-alpine
script:
- find . -name \*.php -exec php -l "{}" \;
lint:php74:
stage: lint
image: php:7.4-alpine
script:
- find . -name \*.php -exec php -l "{}" \;
documentation:
stage: documentation
image:
name: t3docs/render-documentation:v2.4.0
entrypoint: [""]
before_script:
- cp -a ${CI_PROJECT_DIR}/. /PROJECT
- mkdir -p ${CI_PROJECT_DIR}/Documentation-GENERATED-temp
script:
- cd /ALL/venv
- /ALL/Menu/mainmenu.sh makehtml-no-cache -c resultdir ${CI_PROJECT_DIR}/Documentation-GENERATED-temp
artifacts:
paths:
- ${CI_PROJECT_DIR}/Documentation-GENERATED-temp/Result/project/0.0.0
expire_in: 1 day
when: always
sonarqube:
stage: analysis
image: ciricihq/gitlab-sonar-scanner
variables:
SONAR_URL: "https://sonar.extco.de"
SONAR_PROJECT_NAME: "$CI_PROJECT_NAME"
SONAR_TOKEN: "$SONAR_TOKEN"
SONAR_PROJECT_VERSION: "$CI_JOB_ID"
SONAR_ANALYSIS_MODE: "issues"
SONAR_SOURCES: "./Classes"
SONAR_GITLAB_PROJECT_ID: "$CI_PROJECT_ID"
script:
- echo "sonar.projectKey=cart_paypal-5.x" > sonar-project.properties
- gitlab-sonar-scanner -Dsonar.php.coverage.reportPath=phpunit.coverage.xml -Dsonar.php.tests.reportPath=phpunit.report.xml
allow_failure: true
sonarqube-reports:
stage: analysis
image: ciricihq/gitlab-sonar-scanner
variables:
SONAR_URL: "https://sonar.extco.de"
SONAR_PROJECT_NAME: "$CI_PROJECT_NAME"
SONAR_TOKEN: "$SONAR_TOKEN"
SONAR_PROJECT_VERSION: "$CI_JOB_ID"
SONAR_ANALYSIS_MODE: "publish"
SONAR_SOURCES: "./Classes"
SONAR_TESTS: "./Tests"
script:
- echo "sonar.projectKey=cart_paypal-5.x" > sonar-project.properties
- gitlab-sonar-scanner -Dsonar.php.coverage.reportPath=phpunit.coverage.xml -Dsonar.php.tests.reportPath=phpunit.report.xml