tldr/pages/common/phploc.md

33 lines
968 B
Markdown
Raw Normal View History

2018-03-01 17:46:36 +00:00
# phploc
> Quickly measure the size and analyzing the structure of a PHP project.
2019-05-29 14:53:49 +01:00
> More information: <https://github.com/sebastianbergmann/phploc>.
2018-03-01 17:46:36 +00:00
2022-06-27 11:23:12 +01:00
- Analyze a directory and print the result:
2018-03-01 17:46:36 +00:00
`phploc {{path/to/directory}}`
- Include only specific files from a comma-separated list (globs are allowed):
`phploc {{path/to/directory}} --names '{{path/to/file1,path/to/file2,...}}'`
2018-03-01 17:46:36 +00:00
- Exclude specific files from a comma-separated list (globs are allowed):
`phploc {{path/to/directory}} --names-exclude '{{path/to/file1,path/to/file2,...}}'`
2018-03-01 17:46:36 +00:00
- Exclude a specific directory from analysis:
`phploc {{path/to/directory}} --exclude {{path/to/exclude_directory}}`
- Log the results to a specific CSV file:
`phploc {{path/to/directory}} --log-csv {{path/to/file}}`
- Log the results to a specific XML file:
`phploc {{path/to/directory}} --log-xml {{path/to/file}}`
- Count PHPUnit test case classes and test methods:
`phploc {{path/to/directory}} --count-tests`