cvs: peardoc /en/package/php/php-codesniffer usage.xml
| From: | Greg Sherwood | Date: | Tue, 19 May 2009 04:20:04 +0000 |
| Subject: | cvs: peardoc /en/package/php/php-codesniffer usage.xml | ||
| Groups: | php.pear.doc | ||
| Request: | Send a blank email to pear-doc+get-11644@lists.php.net to get a copy of this message | ||
squiz Tue May 19 04:20:04 2009 UTC
Modified files:
/peardoc/en/package/php/php-codesniffer usage.xml
Log:
Added a note describing how to use an external standard with PHP_CodeSniffer
http://cvs.php.net/viewvc.cgi/peardoc/en/package/php/php-codesniffer/usage.xml?r1=1.14&r2=1.15&diff_format=u
Index: peardoc/en/package/php/php-codesniffer/usage.xml
diff -u peardoc/en/package/php/php-codesniffer/usage.xml:1.14
peardoc/en/package/php/php-codesniffer/usage.xml:1.15
--- peardoc/en/package/php/php-codesniffer/usage.xml:1.14 Mon Dec 22 04:00:39 2008
+++ peardoc/en/package/php/php-codesniffer/usage.xml Tue May 19 04:20:04 2009
@@ -208,8 +208,8 @@
<para>
The example below checks the <filename>myfile.inc</filename> file for violations of
the <emphasis>PEAR</emphasis> coding standard (installed by default).
</para>
- <example><info><title>Specifying a coding standard to
use</title></info>
-
+ <example>
+ <info><title>Specifying a coding standard to use</title></info>
<screen>
<userinput>
<![CDATA[
@@ -218,6 +218,21 @@
</userinput>
</screen>
</example>
+ <note>
+ <simpara>
+ Can you also tell PHP_CodeSniffer to use an external standard by specifying the full path to
the standard's root directory on the command line. An external standard is one that is stored
outside of PHP_CodeSniffer's <literal>Standards</literal> directory.
+ </simpara>
+ <example>
+ <info><title>Specifying an external coding standard</title></info>
+ <screen>
+ <userinput>
+<![CDATA[
+$ phpcs --standard=/path/to/MyStandard /path/to/code/myfile.inc
+]]>
+ </userinput>
+ </screen>
+ </example>
+ </note>
</refsection>