sokil/php-library-starter-kit

Starter kit for creating composer compatible library

0.1.0 2019-11-29 10:15 UTC

This package is auto-updated.

Last update: 2024-10-13 05:46:29 UTC


README

Starter kit for creating composer compatible library will help to add boilerplate code. Clone project and start library development with already configured tests, code coverage, code style and quality tools, betchmarking and CI.

Total Downloads Build Status Coverage Status Scrutinizer Code Quality Code Climate

Creating new project

Begin your new library with starter kit. Just create project:

composer create-project sokil/php-library-starter-kit my-php-library --prefer-source

Or you can just clone repo:

git clone https://github.com/sokil/php-library-starter-kit.git my-php-library

Composer commands

  • "test": start unit tests
  • "cover": generate code coverage report to file
  • "coveralls": send code coverage report to coveralls
  • "check-style": check code style by PSR2 rules
  • "fix-style": automatically fix style by PSR2 rules
  • "bench": run phpbench benchmarks,
  • "infection": run mutation tests

External tools

There are some usefull tools for library development, but they written on PHP > 7.0 and this library by default configured for PHP ">=5.3 || ^7.0". So this tools only suggested to be installed or may be installed globally as phar packages or global composer requirement.

PHPBench

Read more at http://phpbench.readthedocs.io. There is some configuration in phpbench.json. Also there is composer script to run infection: composer bench

Infection

Read more at https://infection.github.io. There is some configuration in infection.json.dist. Also there is composer script to run infection: composer infection