mirror of
https://github.com/rectorphp/rector.git
synced 2024-06-04 02:10:51 +00:00
e9e85a1300
|
||
---|---|---|
.. | ||
src | ||
tests | ||
CHANGELOG.md | ||
composer.json | ||
LICENSE.md | ||
phpcs.xml.dist | ||
phpstan.neon.dist | ||
phpunit.xml.dist | ||
README.md |
EditorConfig PHP
PHP implementation of EditorConfig
Installation
Install with Composer:
composer require idiosyncratic/editorconfig
Usage
<?php
require_once('vendor/autoload.php');
use Idiosyncratic\EditorConfig\EditorConfig;
$ec = new EditorConfig();
// $config will be an array of the declarations matching for the specified path
$config = $ec->getConfigForPath(__FILE__);
// Print matching configuration rules as string
print $ec->printConfigForPath(__FILE__) . PHP_EOL;