-
Notifications
You must be signed in to change notification settings - Fork 0
/
.gitlab-ci.yml
52 lines (45 loc) · 950 Bytes
/
.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
image: composer:latest
stages:
- lint
- publish
cache:
paths:
- vendor/
before_script:
- composer install
composer-validate:
stage: lint
script:
- composer validate
tags:
- docker
php-lint:
stage: lint
script:
- cd apnsframework
- if find . -name "*.php" ! -path "./vendor/*" -exec php -l {} \; | grep -v "No syntax errors detected"; then exit 1; fi
tags:
- docker
php-lint-examples:
stage: lint
script:
- cd example
- if find . -name "*.php" ! -path "./vendor/*" -exec php -l {} \; | grep -v "No syntax errors detected"; then exit 1; fi
tags:
- docker
allow_failure: true
publish:
image: node:lts
stage: publish
before_script:
- yarn install
script:
- yarn semantic-release
cache:
key: ${CI_COMMIT_REF_SLUG}
paths:
- .npm/
tags:
- docker
rules:
- if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH && $CI_COMMIT_MESSAGE !~ /chore(release)$/