Skip to content

umbrellio/code-style-php

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

php-config-umbrellio

Settings used in Umbrellio php projects.


Installation

Install via composer:

php composer.phar require --dev umbrellio/code-style-php

Create config ecs.yml:

imports:
  - { resource: vendor/umbrellio/code-style-php/umbrellio-cs.yml }

If major version of EasyCodingStandard 9 or higher create config ecs.php:

<?php

declare(strict_types=1);

use Symfony\Component\DependencyInjection\Loader\Configurator\ContainerConfigurator;

return static function(ContainerConfigurator $containerConfigurator): void {
    $containerConfigurator->import(__DIR__ . '/vendor/umbrellio/code-style-php/umbrellio-cs.php');
};

Usage

Run in CLI:

vendor/bin/ecs check src --fix --config=ecs.yml

or:

vendor/bin/ecs check src --fix --config=ecs.php

Dependencies (and Links)


License

Released under MIT License.

Contributing

  • Fork it ( https://github.com/umbrellio/code-style-php )
  • Create your feature branch (git checkout -b feature/my-new-feature)
  • Commit your changes (git commit -am 'Add some feature')
  • Push to the branch (git push origin feature/my-new-feature)
  • Create new Pull Request

Supported by Umbrellio