Skip to content

Commit

Permalink
Separate step for linting in travis matrix. Readded phpdocumentor
Browse files Browse the repository at this point in the history
  • Loading branch information
massimilianobraglia committed Dec 21, 2018
1 parent 84612d5 commit eb2036b
Show file tree
Hide file tree
Showing 6 changed files with 42 additions and 8 deletions.
5 changes: 3 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ env:
- TARGET="71"
- TARGET="72"
- TARGET="73"
- TARGET="Lint"

before_install:
# check running "docker engine" and "docker-compose" version on travis
Expand All @@ -41,8 +42,8 @@ before_script:
- sudo sysctl -w vm.max_map_count=262144

script:
- make tests TARGET=$TARGET
- if [ "$TARGET" == "72" ] ; then make check-style ; fi
- if [ "$TARGET" != "Lint" ] ; then make tests TARGET=$TARGET ; fi
- if [ "$TARGET" == "Lint" ] ; then make check-style ; fi

after_script:
- cat /var/log/elasticsearch/*.log
Expand Down
2 changes: 0 additions & 2 deletions env/elastica/Docker70
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,5 @@ ENV PATH=/root/composer/vendor/bin:$PATH

COPY composer.json /root/composer/

RUN composer global require --no-update friendsofphp/php-cs-fixer:^2.0

# Install development tools, prefer source removed as automatic fallback now
RUN composer global install
2 changes: 0 additions & 2 deletions env/elastica/Docker71
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,5 @@ ENV PATH=/root/composer/vendor/bin:$PATH

COPY composer.json /root/composer/

RUN composer global require --no-update friendsofphp/php-cs-fixer:^2.0

# Install development tools, prefer source removed as automatic fallback now
RUN composer global install
2 changes: 0 additions & 2 deletions env/elastica/Docker72
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,5 @@ ENV PATH=/root/composer/vendor/bin:$PATH

COPY composer.json /root/composer/

RUN composer global require --no-update friendsofphp/php-cs-fixer:^2.0

# Install development tools, prefer source removed as automatic fallback now
RUN composer global install
38 changes: 38 additions & 0 deletions env/elastica/Lint
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
# This image is the base image for the Elastica development and includes all parts which rarely change
# PHP 7 Docker file with Composer installed
FROM php:7.2
MAINTAINER Nicolas Ruflin <[email protected]>

RUN apt-get update && apt-get install -y \
cloc \
git \
graphviz \
libxslt-dev \
nano \
zip unzip \
wget
# XSL and Graphviz for PhpDocumentor

RUN docker-php-ext-install sockets xsl

RUN rm -r /var/lib/apt/lists/*

# Xdebug for coverage report
RUN pecl install xdebug-2.6.1

RUN echo "memory_limit=1024M" >> /usr/local/etc/php/conf.d/memory-limit.ini
RUN echo "date.timezone=UTC" >> /usr/local/etc/php/conf.d/timezone.ini

# Install and setup composer
RUN curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer
ENV COMPOSER_HOME /root/composer

# Add composer bin to the environment
ENV PATH=/root/composer/vendor/bin:$PATH

COPY composer.json /root/composer/

RUN composer global require --no-update friendsofphp/php-cs-fixer:^2.0

# Install development tools, prefer source removed as automatic fallback now
RUN composer global install
1 change: 1 addition & 0 deletions env/elastica/composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
],
"require": {
"php": "^7.0",
"phpdocumentor/phpdocumentor": "^2.9",
"mayflower/php-codebrowser": "~1.1",
"pdepend/pdepend": "^2.5",
"phploc/phploc": "^4.0",
Expand Down

0 comments on commit eb2036b

Please sign in to comment.