PHP coding standard used at Mogic GmbH

v1.2.0 2022-03-04 12:27 UTC

This package is auto-updated.

Last update: 2023-03-09 08:11:23 UTC



Create your own phpcs.xml file from this template and adjust it:

<?xml version="1.0"?>
<ruleset name="bellevue">
  <description>project-specific coding standard</description>



  <rule ref="./vendor/mogic/mogic-phpcs/Mogic/"/>

Project with composer

The repository is mirrored automatically to Github: The package is also available on packagist:

Now run:

$ composer require --dev mogic/mogic-phpcs:dev-master

Then commit composer.json and composer.lock.

During the build, composer install needs to be called, which will fetch the coding standard from git. To make this work, the build container needs to contain a SSH key that has read-only access to the coding standards repository.

Example: reos-docker -> web-build

Project without composer dependencies

In a project, create a composer.json file:

    "name": "customer/projectname",
    "description": "FIXME",
    "license": "proprietary",
    "require-dev": {
        "mogic/mogic-phpcs": "dev-master"

Adjust Makefile:

      rm -rf vendor
      composer install
      rm -rf vendor/autoload.php vendor/composer/ vendor/mogic/mogic-phpcs/.git/

Now run make update-phpcs and git commit the vendor/ dir, composer.json and composer.lock.