Manual:checkSyntax.php
Appearance
この機能は、バージョン 1.31.0 で完全に除去されました。 |
MediaWiki ファイル: checkSyntax.php | |
---|---|
場所: | maintenance/ |
ソース コード: | master • 1.42.3 • 1.41.4 • 1.39.10 |
クラス: | CheckSyntax |
This command-line maintenance script checks source files for syntax errors and common coding mistakes, such as byte order marks, pointless PHP closing tags (?>
) at the end of file and whitespace before the opening tag (<?php
).
使用法
If called without arguments, checkSyntax.php
scans through main code directories (/includes/
, /config/
, /languages/
, /maintenance/
and /skins/
) and, if it exists, checks the configuration file LocalSettings.php . For example:
Command-line options:
--with-extensions
- also scan the
/extensions/
directory. --path <path to check>
- check the given file or directory.
--list-file <filename>
- check only files or directories listed in the given text file.
--modified
- check only files modified in the current working copy (requires that the script is run from a Git clone and that the Git command-line client is present. Use this option to quickly check your changes before committing them to your repository.