-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
41 lines (36 loc) · 1.5 KB
/
.travis.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
language: php
sudo: false
php:
- 7.2
before_install:
- echo "memory_limit=2G" >> ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini
install:
- composer global require hirak/prestissimo
- composer global require drush/drush:8.x-dev drupal/coder mglaman/drupal-check friendsoftwig/twigcs
- export PATH="$HOME/.config/composer/vendor/bin:$PATH"
- phpcs --config-set installed_paths ../../drupal/coder/coder_sniffer
- phpenv rehash
- nvm install node
- nvm use node
- npm install --global yarn
- cd ../ && composer create-project drupal-composer/drupal-project:8.x-dev drupal --no-interaction
- cd drupal
- DRUPAL_ROOT=$(pwd)/web
- export REPOSITORIES='"repositories":\ \['
- export REPOSITORIES_REPLACE='"repositories":\[\{"type":"path","url":"..\/os2web_pagebuilder","options":\{"symlink":false\}\},'
- export REQUIRE='"require":\ {'
- export REQUIRE_REPLACE='"require":{"os2web\/os2web_person_information":"\*",'
- sed -i "s/$REPOSITORIES/$REPOSITORIES_REPLACE/g" composer.json
- sed -i "s/$REQUIRE/$REQUIRE_REPLACE/g" composer.json
- composer update os2web/os2web_person_information
- PROJECT_PATH=$DRUPAL_ROOT/modules/contrib/os2web_person_information
- cd $DRUPAL_ROOT/core
- yarn install
- npm install --global eslint-config-drupal-bundle stylelint
script:
- phpcs --standard=Drupal --ignore=*.md $PROJECT_PATH
- twigcs $PROJECT_PATH
- cd $DRUPAL_ROOT/core
- eslint $PROJECT_PATH
- stylelint --aei $PROJECT_PATH/**/*.css
- drupal-check $PROJECT_PATH