pluswerk / grumphp-typoscript-task
将Martin Helmich的TypoScript代码检查工具与grumphp连接,并添加一些嗅探器。
v0.0.4
2019-11-26 14:53 UTC
Requires
- php: >=7.2.0
- helmich/typo3-typoscript-lint: ^2.0
- phpro/grumphp: ^0.16.2
- typo3/minimal: ^9.5
Requires (Dev)
- dg/bypass-finals: ^1.1
- phpunit/phpunit: ^8.4
- pluswerk/grumphp-config: ^3.0
This package is auto-updated.
Last update: 2024-08-27 01:44:47 UTC
README
grumphp-typoscript-task
GrumPHP任务,用于检查TYPO3 CMS TypoScript文件。
此包基于Martin Helmich的martin-helmich/typo3-typoscript-lint,向grumphp添加了一个TYPO3 CMS TypoScript文件检查任务。
快速指南
grumphp.yml
在grumphp.yml中的基本包含
parameters: tasks: typoscriptlint: ~ extensions: - Pluswerk\TypoScriptLinter\ExtensionLoader
Composer
composer require --dev pluswerk/grumphp-typoscript-task
配置
typoscript linter
可以在与grumphp相同的配置方式下配置grumphp.yml文件中的linter,请参见TypoScript Linter配置
示例
parameters: tasks: typoscriptlint: sniffs: - class: Indentation parameters: useSpaces: true indentPerLevel: 2 indentConditions: true - class: DeadCode extensions: - Pluswerk\TypoScriptLinter\ExtensionLoader
triggered_by
触发linter的文件扩展名。
parameters: tasks: typoscriptlint: triggered_by: - 'typoscript'
ignore_patterns
使用grumphp忽略模式忽略文件。
parameters: tasks: typoscriptlint: ignore_patterns: - 'pattern'