sandergerritsen / gerritci
Continuous Integration using Composer
1.0.1
2020-01-05 20:47 UTC
Requires
- php: >=7.1.0
This package is auto-updated.
Last update: 2025-06-13 01:05:20 UTC
README
Continuous integration for PHP projects using composer.
Use composer for development and production
The goals for this project is to have one single composer.json file to be used in both development and production.
- For development we need a few packages installed locally
- For production we like composer to get all data from remote GIT repositories
Usage
- Setup your composer.json file for development
- Use
@dev
ordev-master
as tag name - Add a
repository
withtype: 'path'
url: '../../packages/my-package'
, reference you locally cloned package
- Use
>Example:
{ "require": { "my-vendor/my-package": "@dev" }, "repositories": [ { "name": "my-vendor/my-package", "type": "path", "url": "../../packages/my-package", "options": { "symlink": false } } ] }
- Add production configuration to the
"extra": { }
part- GerritCI will overwrite the
tag
,type
andurl
values in therequire
section, linked by the package name{ "extra": { "gerritci": { "my-vendor/my-package": { "tag": "1.0.*", "repository": { "type": "vcs", "url": "git@gitlab.com:sandergerritsen/my-package.git" } } } } }
- GerritCI will overwrite the
- After successfully running
gerritci
command line, runcomposer update
to update the composer.lock file- Or maybe better: run
composer update phpunit/phpunit
. Select any package from yourrequire-dev
section. That will only update that single package. And as this is a dev requirement only, it will not unintentionally update any packages used in a production environment.
- Or maybe better: run