Skip to content

Commit a504542

Browse files
committed
Added the phpcbf.bat file
1 parent 784303b commit a504542

4 files changed

Lines changed: 24 additions & 5 deletions

File tree

package.xml

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ http://pear.php.net/dtd/package-2.0.xsd">
2828
<notes>
2929
- PHPCBF will now fix incorrect newline characters in a file
3030
- PHPCBF now exists cleanly when there are no errors to fix
31+
- Added phpcbf.bat file for Windows
3132
- Fixed a problem that could occur with line numbers when using HHVM to check files with Windows newline characters
3233
- Fixed bug #20261 : phpcbf has an endless fixing loop
3334
</notes>
@@ -53,7 +54,11 @@ http://pear.php.net/dtd/package-2.0.xsd">
5354
<tasks:replace from="@php_bin@" to="php_bin" type="pear-config" />
5455
<tasks:replace from="@bin_dir@" to="bin_dir" type="pear-config" />
5556
<tasks:replace from="@php_dir@" to="php_dir" type="pear-config" />
56-
<tasks:replace from="@package_version@" to="version" type="package-info" />
57+
</file>
58+
<file baseinstalldir="" name="phpcbf.bat" role="script">
59+
<tasks:replace from="@php_bin@" to="php_bin" type="pear-config" />
60+
<tasks:replace from="@bin_dir@" to="bin_dir" type="pear-config" />
61+
<tasks:replace from="@php_dir@" to="php_dir" type="pear-config" />
5762
</file>
5863
</dir>
5964
<dir name="tests">
@@ -2186,9 +2191,10 @@ http://pear.php.net/dtd/package-2.0.xsd">
21862191
</os>
21872192
</installconditions>
21882193
<filelist>
2189-
<install as="phpcbf" name="scripts/phpcbf" />
21902194
<install as="phpcs" name="scripts/phpcs" />
2195+
<install as="phpcbf" name="scripts/phpcbf" />
21912196
<install as="phpcs.bat" name="scripts/phpcs.bat" />
2197+
<install as="phpcbf.bat" name="scripts/phpcbf.bat" />
21922198
<install as="AllTests.php" name="tests/AllTests.php" />
21932199
<install as="TestSuite.php" name="tests/TestSuite.php" />
21942200
<install as="CodeSniffer/Core/AllTests.php" name="tests/Core/AllTests.php" />
@@ -2201,8 +2207,8 @@ http://pear.php.net/dtd/package-2.0.xsd">
22012207
</phprelease>
22022208
<phprelease>
22032209
<filelist>
2204-
<install as="phpcbf" name="scripts/phpcbf" />
22052210
<install as="phpcs" name="scripts/phpcs" />
2211+
<install as="phpcbf" name="scripts/phpcbf" />
22062212
<install as="AllTests.php" name="tests/AllTests.php" />
22072213
<install as="TestSuite.php" name="tests/TestSuite.php" />
22082214
<install as="CodeSniffer/Core/AllTests.php" name="tests/Core/AllTests.php" />
@@ -2212,6 +2218,7 @@ http://pear.php.net/dtd/package-2.0.xsd">
22122218
<install as="CodeSniffer/Standards/AllSniffs.php" name="tests/Standards/AllSniffs.php" />
22132219
<install as="CodeSniffer/Standards/AbstractSniffUnitTest.php" name="tests/Standards/AbstractSniffUnitTest.php" />
22142220
<ignore name="scripts/phpcs.bat" />
2221+
<ignore name="scripts/phpcbf.bat" />
22152222
</filelist>
22162223
</phprelease>
22172224
<changelog>

scripts/phpcbf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
* @category PHP
99
* @package PHP_CodeSniffer
1010
* @author Greg Sherwood <[email protected]>
11-
* @copyright 2006-2012 Squiz Pty Ltd (ABN 77 084 670 600)
11+
* @copyright 2006-2014 Squiz Pty Ltd (ABN 77 084 670 600)
1212
* @license https://github.com/squizlabs/PHP_CodeSniffer/blob/master/licence.txt BSD Licence
1313
* @link http://pear.php.net/package/PHP_CodeSniffer
1414
*/

scripts/phpcbf.bat

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
@echo off
2+
REM PHP Code Beautifier and Fixer
3+
REM
4+
REM PHP version 5
5+
REM
6+
REM @category PHP
7+
REM @package PHP_CodeSniffer
8+
REM @author Greg Sherwood <[email protected]>
9+
REM @copyright 2006-2014 Squiz Pty Ltd (ABN 77 084 670 600)
10+
REM @license https://github.com/squizlabs/PHP_CodeSniffer/blob/master/licence.txt BSD Licence
11+
REM @link http://pear.php.net/package/PHP_CodeSniffer
12+
13+
"@php_bin@" -d auto_append_file="" -d auto_prepend_file="" -d include_path="'@php_dir@'" -f "@bin_dir@\phpcbf" -- %*

scripts/phpcs.bat

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ REM @author Greg Sherwood <[email protected]>
1010
REM @author Marc McIntyre <[email protected]>
1111
REM @copyright 2006-2014 Squiz Pty Ltd (ABN 77 084 670 600)
1212
REM @license https://github.com/squizlabs/PHP_CodeSniffer/blob/master/licence.txt BSD Licence
13-
REM @version CVS: $Id: phpcs.bat,v 1.3 2007-11-04 22:02:16 squiz Exp $
1413
REM @link http://pear.php.net/package/PHP_CodeSniffer
1514

1615
"@php_bin@" -d auto_append_file="" -d auto_prepend_file="" -d include_path="'@php_dir@'" -f "@bin_dir@\phpcs" -- %*

0 commit comments

Comments
 (0)