Find a bug? Help us fix it.
-
Fork from Github.
-
Clone your fork and load dependencies:
$ git clone [email protected]:${YOUR_GITHUB_USERNAME}/zapcore.git $ cd zapcore $ composer -vvv install -no
-
Make your changes. Sources are in
./src
and occasionally also in./dev
directories.$ # do your thing, e.g.: $ vim src/Router.php
-
Adjust the tests. Make sure there's no failure. Tests are in
./tests
directory.$ # adjust tests, e.g.: $ vim tests/RouterTest.php $ # run tests $ phpunit || echo 'Boo!'
-
Make sure code coverage is at 100% or close. If you have Xdebug installed, coverage report is available with:
$ phpunit $ x-www-browser docs/coverage/index.html
-
Make sure coding convention is met as much as possible. For automated check, use code sniffer and mess detector rulesets that come with this repository:
$ export PATH=~/.composer/vendor/bin:$PATH $ $ # coding convention compliance with phpcs $ composer global require squizlabs/php_codesniffer $ phpcs $ $ # static analysis with phpmd $ composer global require phpmd/phpmd $ phpmd ./src text ./phpmd.xml
-
Push to your fork and submit a Pull Request.