mirror of
https://github.com/tldr-pages/tldr.git
synced 2025-04-23 23:02:08 +02:00
phpmd: add page
This commit is contained in:
parent
4c08ebfd28
commit
c59f83ba27
1 changed files with 31 additions and 0 deletions
31
pages/common/phpmd.md
Normal file
31
pages/common/phpmd.md
Normal file
|
@ -0,0 +1,31 @@
|
|||
# phpmd
|
||||
|
||||
> A PHP mess detector that checks for common potential problems.
|
||||
|
||||
- Display a list of available rulesets and formats:
|
||||
|
||||
`phpmd`
|
||||
|
||||
- Scan a file or directory for problems using comma-separated rulesets:
|
||||
|
||||
`phpmd {{path/to/file_or_directory}} {{xml|text|html}} {{rulesets}}`
|
||||
|
||||
- Specify the minimum priority threshold for rules:
|
||||
|
||||
`phpmd {{path/to/file_or_directory}} {{xml|text|html}} {{rulesets}} --minimumpriority {{priority}}`
|
||||
|
||||
- Include only the specified extensions in analysis:
|
||||
|
||||
`phpmd {{path/to/file_or_directory}} {{xml|text|html}} {{rulesets}} --suffixes {{extensions}}`
|
||||
|
||||
- Exclude the specified comma-separated directories:
|
||||
|
||||
`phpmd {{path/to/file_or_directory}} {{xml|text|html}} {{rulesets}} --exclude {{directory_patterns}}`
|
||||
|
||||
- Output the results to a file instead of stdout:
|
||||
|
||||
`phpmd {{path/to/file_or_directory}} {{xml|text|html}} {{rulesets}} --reportfile {{path/to/report_file}}`
|
||||
|
||||
- Ignore the use of warning-suppression PHPDoc comments:
|
||||
|
||||
`phpmd {{path/to/file_or_directory}} {{xml|text|html}} {{rulesets}} --strict`
|
Loading…
Add table
Reference in a new issue