dancryer / PHPCI

PHPCI is a free and open source continuous integration tool specifically designed for PHP.
BSD 2-Clause "Simplified" License
2.42k stars 441 forks source link

Add support for rebuild on Git webhook #1346

Closed mathysie closed 6 years ago

mathysie commented 6 years ago

Enables for example a maintainer to run a daily build of their project, whether a change has been made or not. The rebuild parameter is made fully optional.

Contribution Type: new feature

This pull request affects the following areas:

In raising this pull request, I confirm the following (please check boxes):

Detailed description of change:

An optional parameter rebuild has been added to WebhookController::createBuild. This allows a maintainer to use the git webhook to start a rebuild of their project. At our project we want an automatic daily build of the project and this feature supports it.

In WebhookController::git the parameter rebuild can be read, where it is false if no parameter has been given. The parameter $rebuild is then passed to WebhookController::createBuild. There the parameter $rebuild is also made optional and false by default, such that other calls to createBuild are still supported.