Loading Dockerfile +3 −0 Original line number Diff line number Diff line Loading @@ -13,6 +13,9 @@ ENV PHP_CONF_DIR=/etc/php/${PHP_VERSION} RUN pecl install ast && \ echo "extension=ast.so" > ${PHP_CONF_DIR}/cli/conf.d/ast.ini # PHAN n'aime pas xdebug RUN phpdismod xdebug # Nettoyage RUN apt-get autoremove -y && apt-get clean && rm -rf /tmp/* /var/tmp/* Loading bin/check-compat.mddeleted 100644 → 0 +0 −52 Original line number Diff line number Diff line # check-compat Tester la compatibilité des bibliothèques `unicaen/*` avec une version précise de PHP. ## PHP 7.0 ```bash docker run \ --rm \ -v ${PWD}:/app \ --workdir /app \ unicaen-dev-php7.0-apache \ ./bin/check-compat.sh 7.0 ``` ## PHP 7.1 ```bash docker run \ --rm \ -v ${PWD}:/app \ --workdir /app \ unicaen-dev-php7.0-apache \ ./bin/check-compat.sh 7.1 ``` ## PHP 7.2 ```bash docker run \ --rm \ -v ${PWD}:/app \ --workdir /app \ unicaen-dev-php7.0-apache \ ./bin/check-compat.sh 7.2 ``` ## PHP 7.3 ```bash docker run \ --rm \ -v ${PWD}:/app \ --workdir /app \ unicaen-dev-php7.0-apache \ ./bin/check-compat.sh 7.3 ``` bin/check-compat.shdeleted 100755 → 0 +0 −33 Original line number Diff line number Diff line #!/usr/bin/env bash [[ -z $1 ]] && echo "Veuillez spécifier les versions de PHP désirées (ex: 7.1 7.2 7.3)." && exit 1 DIR=$(cd `dirname $0` && pwd) DIRNAME=$(basename ${DIR}) cd ${DIR}/.. versions=$1 phpcs="./vendor/bin/phpcs" libdir="./vendor/unicaen" outdir="./${DIRNAME}/reports" mkdir -p ${outdir} #&& rm -rf ${outdir}/* for path in ${libdir}/* do dirname=$(basename -- "$path") for ver in "$1" do reportpath="${outdir}/compat-unicaen-${dirname}-${ver}.txt" echo "Processing '${path}' against PHP version ${ver}" echo "=> reporting into '${reportpath}'" ${phpcs} \ -p \ --standard=PHPCompatibility \ --runtime-set testVersion ${ver} \ --report-full=${reportpath} \ ${path} done done bin/php-compat-run.shdeleted 100755 → 0 +0 −33 Original line number Diff line number Diff line #!/usr/bin/env bash [[ -z $1 ]] && echo "Veuillez spécifier la version de PHP désirée (ex: 7.2)." && exit 1 DIR=$(cd `dirname $0` && pwd) v=$1 unicaenlogfile=/tmp/phan-unicaen-${v}.log vendorslogfile=/tmp/phan-vendors-${v}.log DIR=$(cd `dirname $0` && pwd) docker-compose -f ${DIR}/../docker-compose.yml build docker exec \ unicaen-php-compat-${v}-container \ vendor/bin/phan \ --config-file .phan/config-unicaen.php \ --target-php-version ${v} \ > ${unicaenlogfile} docker exec \ unicaen-php-compat-${v}-container \ vendor/bin/phan \ --config-file .phan/config-vendor.php \ --target-php-version ${v} \ > ${unicaenlogfile} echo echo "See ${unicaenlogfile}." echo "See ${vendorslogfile}." echo bin/phpcs.sh +1 −6 Original line number Diff line number Diff line Loading @@ -15,20 +15,15 @@ PHP_VERSION_ID=$((a[0]*10000+a[1]*100+a[2])) phpcs="./vendor/bin/phpcs" libdir="./vendor/unicaen" reportpath="/tmp/unicaen-${version}.log" echo "" > ${reportpath} for path in ${libdir}/* do dirname=$(basename -- "$path") echo "Processing '${path}' against PHP version ${version} (PHP_VERSION_ID=${PHP_VERSION_ID})" echo ${phpcs} \ -p \ --standard=PHPCompatibility \ --runtime-set php_version ${PHP_VERSION_ID} \ --report-full ${reportpath} \ ${path} done echo "Done. See '${reportpath}'." Loading
Dockerfile +3 −0 Original line number Diff line number Diff line Loading @@ -13,6 +13,9 @@ ENV PHP_CONF_DIR=/etc/php/${PHP_VERSION} RUN pecl install ast && \ echo "extension=ast.so" > ${PHP_CONF_DIR}/cli/conf.d/ast.ini # PHAN n'aime pas xdebug RUN phpdismod xdebug # Nettoyage RUN apt-get autoremove -y && apt-get clean && rm -rf /tmp/* /var/tmp/* Loading
bin/check-compat.mddeleted 100644 → 0 +0 −52 Original line number Diff line number Diff line # check-compat Tester la compatibilité des bibliothèques `unicaen/*` avec une version précise de PHP. ## PHP 7.0 ```bash docker run \ --rm \ -v ${PWD}:/app \ --workdir /app \ unicaen-dev-php7.0-apache \ ./bin/check-compat.sh 7.0 ``` ## PHP 7.1 ```bash docker run \ --rm \ -v ${PWD}:/app \ --workdir /app \ unicaen-dev-php7.0-apache \ ./bin/check-compat.sh 7.1 ``` ## PHP 7.2 ```bash docker run \ --rm \ -v ${PWD}:/app \ --workdir /app \ unicaen-dev-php7.0-apache \ ./bin/check-compat.sh 7.2 ``` ## PHP 7.3 ```bash docker run \ --rm \ -v ${PWD}:/app \ --workdir /app \ unicaen-dev-php7.0-apache \ ./bin/check-compat.sh 7.3 ```
bin/check-compat.shdeleted 100755 → 0 +0 −33 Original line number Diff line number Diff line #!/usr/bin/env bash [[ -z $1 ]] && echo "Veuillez spécifier les versions de PHP désirées (ex: 7.1 7.2 7.3)." && exit 1 DIR=$(cd `dirname $0` && pwd) DIRNAME=$(basename ${DIR}) cd ${DIR}/.. versions=$1 phpcs="./vendor/bin/phpcs" libdir="./vendor/unicaen" outdir="./${DIRNAME}/reports" mkdir -p ${outdir} #&& rm -rf ${outdir}/* for path in ${libdir}/* do dirname=$(basename -- "$path") for ver in "$1" do reportpath="${outdir}/compat-unicaen-${dirname}-${ver}.txt" echo "Processing '${path}' against PHP version ${ver}" echo "=> reporting into '${reportpath}'" ${phpcs} \ -p \ --standard=PHPCompatibility \ --runtime-set testVersion ${ver} \ --report-full=${reportpath} \ ${path} done done
bin/php-compat-run.shdeleted 100755 → 0 +0 −33 Original line number Diff line number Diff line #!/usr/bin/env bash [[ -z $1 ]] && echo "Veuillez spécifier la version de PHP désirée (ex: 7.2)." && exit 1 DIR=$(cd `dirname $0` && pwd) v=$1 unicaenlogfile=/tmp/phan-unicaen-${v}.log vendorslogfile=/tmp/phan-vendors-${v}.log DIR=$(cd `dirname $0` && pwd) docker-compose -f ${DIR}/../docker-compose.yml build docker exec \ unicaen-php-compat-${v}-container \ vendor/bin/phan \ --config-file .phan/config-unicaen.php \ --target-php-version ${v} \ > ${unicaenlogfile} docker exec \ unicaen-php-compat-${v}-container \ vendor/bin/phan \ --config-file .phan/config-vendor.php \ --target-php-version ${v} \ > ${unicaenlogfile} echo echo "See ${unicaenlogfile}." echo "See ${vendorslogfile}." echo
bin/phpcs.sh +1 −6 Original line number Diff line number Diff line Loading @@ -15,20 +15,15 @@ PHP_VERSION_ID=$((a[0]*10000+a[1]*100+a[2])) phpcs="./vendor/bin/phpcs" libdir="./vendor/unicaen" reportpath="/tmp/unicaen-${version}.log" echo "" > ${reportpath} for path in ${libdir}/* do dirname=$(basename -- "$path") echo "Processing '${path}' against PHP version ${version} (PHP_VERSION_ID=${PHP_VERSION_ID})" echo ${phpcs} \ -p \ --standard=PHPCompatibility \ --runtime-set php_version ${PHP_VERSION_ID} \ --report-full ${reportpath} \ ${path} done echo "Done. See '${reportpath}'."