First you need to create phpci.yml file in your project's root directory, in your case it will be myproject/phpci.yml . This file contains configuration and usage of plugins. You might also need those plugins in your project for PHP-CI to test build. Use composer to to include those plugins in your project. To do that add another file in your project's root directory myproject/composer.json.
This happens when PHP-CI cannot find a plugin from its own directory, then it uses project's vendor directory to execute those plugins.
Example File/Config Format:
Suppose you have directory structure like this:
- ./myproject/
- ./myproject/protected/
- ./myproject/assets/
- ./myproject/protected/runtime/
and you want to run PHP-CI on ./myproject/protected/ while looking to skip ./myproject/assets/ & ./myproject/protected/runtime/ directories then your phpci.yml will look like this:
phpci.yml
build_settings:
ignore:
- "assets"
- "protected/runtime/"
setup:
composer:
action: "install"
test:
php_parallel_lint:
directory: "protected"
ignore:
- "assets"
- "protected/runtime"
php_code_sniffer:
path: "protected"
ignore:
- "assets"
- "protected/runtime"
standard: "code-sniffer-settings.xml"
allowed_errors: 10
allowed_warnings: 10
php_unit:
config:
- "protected/tests/phpunit.xml"
args: "--stderr"
path: "protected/tests/unit"
php_cpd:
allow_failures: true
path: "protected"
ignore:
- "assets"
- "protected/runtime"
php_docblock_checker:
allowed_warnings: -1
path: "protected"
ignore:
- "assets"
- "protected/runtime"
php_loc:
directory: "protected"
pdepend:
directory: "protected"
composer.json
{
"require-dev": {
"squizlabs/php_codesniffer": "2.*",
"sebastian/phpdcd": "*",
"phpmd/phpmd" : "@stable",
"phpunit/phpunit": "4.0.*",
"sebastian/phpcpd": "*",
"jakub-onderka/php-parallel-lint": "0.*",
"phpunit/php-code-coverage": "2.0.0",
"pdepend/pdepend": "2.2.2"
}
}
As to answer your question:
Which part of this file should I edit to include it in my project
Change test: section in phpci.yml and remove extra plugins that you don't want to be executed by PHP-CI, while leave composer section as it is, PHP-CI will run composer automatically on its own when testing a build.