diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml new file mode 100644 index 0000000000000000000000000000000000000000..3e0e28a5255007dbeb3e5d1a3af59030eb3795c2 --- /dev/null +++ b/.gitlab-ci.yml @@ -0,0 +1,37 @@ +image: localhost:5000/unicaen-dev-php7.3-apache + +stages: + - tests + - release + - publish + +cache: + key: ${CI_COMMIT_REF_SLUG} + paths: + - vendor/ + +#unit-tests: +# stage: tests +# script: +# - composer install --no-interaction --no-suggest --no-progress +# - php vendor/bin/phpunit --coverage-text=coverage.txt --colors=never +# artifacts: +# paths: +# - coverage.txt + +update-satis: + stage: publish + script: + - curl https://gest.unicaen.fr/packagist/update + +release_job: + stage: release + image: registry.gitlab.com/gitlab-org/release-cli:latest + rules: + - if: $CI_COMMIT_TAG # Run this job when a tag is created manually + script: echo "Creation de la release $CI_COMMIT_TAG..." + release: + name: '$CI_COMMIT_TAG' + tag_name: '$CI_COMMIT_TAG' + ref: '$CI_COMMIT_TAG' + description: 'Cf. [CHANGELOG](CHANGELOG.md) et [Release notes](doc/release-notes/v$CI_COMMIT_TAG.md)'