diff --git a/README.md b/README.md index 7295726..ec8c8b2 100644 --- a/README.md +++ b/README.md @@ -37,6 +37,9 @@ These code standards are extendable, all you need to do is create your own `ecs. ```php getParameter(Option::SKIP); + + $ecsConfig->skip(array_merge($jumpSkips, [ + UnusedParameterSniff::class => [ + __DIR__ . '/app/Console/Kernel.php', + __DIR__ . '/app/Exceptions/Handler.php', + ], + 'Unused parameter $attributes.' => [ + __DIR__ . '/database/*.php', + ], + CamelCapsFunctionNameSniff::class => [ + '/tests/**', + ], + ])); }; ``` diff --git a/src/Support/ConfigHelper.php b/src/Support/ConfigHelper.php new file mode 100644 index 0000000..ed000a5 --- /dev/null +++ b/src/Support/ConfigHelper.php @@ -0,0 +1,31 @@ +config); + + $containerProperty = $reflectedConfig->getParentClass()->getProperty('container'); + + $containerProperty->setAccessible(true); + + return $containerProperty->getValue($this->config)->getParameter($name); + } +}