xenforo-ltd / xf-cs-fixer
A PHP Coding Standards Fixer configuration for XenForo
Requires
- php: ^7.4 || ^8.0
- friendsofphp/php-cs-fixer: ^3.89.1
Requires (Dev)
Suggests
None
Provides
None
Conflicts
None
Replaces
None
README
A PHP Coding Standards Fixer configuration for the XenForo code style. It provides a configuration helper and custom rules that supplement the built-in PER-CS rule set.
Installation
Install the package with Composer:
composer require --dev xenforo-ltd/xf-cs-fixer
Usage
Create a .php-cs-fixer.dist.php configuration file in your project directory:
<?php declare(strict_types=1); use PhpCsFixer\Finder; use XFCsFixer\ConfigHelper; $finder = Finder::create() ->in(__DIR__) ->ignoreVCSIgnored(true); $helper = new ConfigHelper($finder); return $helper->getConfig();
Check or fix your project's formatting:
vendor/bin/php-cs-fixer check vendor/bin/php-cs-fixer fix
For more information, consult the PHP Coding Standards Fixer documentation.
Security
Do not report security vulnerabilities in public issues.
See SECURITY.md for vulnerability reporting instructions.
Support
For usage questions, ask in the development discussions forum. For bug reports and feature requests, use this repository's GitHub Issues.
For support guidance, see SUPPORT.md.
Contributing
See CONTRIBUTING.md for development and contribution guidelines.
License
Copyright (c) XenForo Ltd. All rights reserved.
This project is licensed under the MIT License. See LICENSE for details.