Skip to content

Commit 000d6c1

Browse files
committed
Re-added support for the .bat files
1 parent d9acb03 commit 000d6c1

File tree

4 files changed

+26
-44
lines changed

4 files changed

+26
-44
lines changed
Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,14 @@
11
@echo off
2-
REM PHP Code Beautifier and Fixer
2+
REM PHP Code Beautifier and Fixer fixes violations of a defined coding standard.
33
REM
4-
REM PHP version 5
5-
REM
6-
REM @category PHP
7-
REM @package PHP_CodeSniffer
84
REM @author Greg Sherwood <gsherwood@squiz.net>
9-
REM @copyright 2006-2014 Squiz Pty Ltd (ABN 77 084 670 600)
5+
REM @copyright 2006-2015 Squiz Pty Ltd (ABN 77 084 670 600)
106
REM @license https://github.com/squizlabs/PHP_CodeSniffer/blob/master/licence.txt BSD Licence
11-
REM @link http://pear.php.net/package/PHP_CodeSniffer
127

138
if "%PHPBIN%" == "" set PHPBIN=@php_bin@
149
if not exist "%PHPBIN%" if "%PHP_PEAR_PHP_BIN%" neq "" goto USE_PEAR_PATH
1510
GOTO RUN
1611
:USE_PEAR_PATH
1712
set PHPBIN=%PHP_PEAR_PHP_BIN%
1813
:RUN
19-
"%PHPBIN%" "@bin_dir@\phpcbf" %*
14+
"%PHPBIN%" "@bin_dir@\phpcbf" %*

bin/phpcs.bat

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
@echo off
2+
REM PHP_CodeSniffer detects violations of a defined coding standard.
3+
REM
4+
REM @author Greg Sherwood <gsherwood@squiz.net>
5+
REM @copyright 2006-2015 Squiz Pty Ltd (ABN 77 084 670 600)
6+
REM @license https://github.com/squizlabs/PHP_CodeSniffer/blob/master/licence.txt BSD Licence
7+
8+
if "%PHPBIN%" == "" set PHPBIN=@php_bin@
9+
if not exist "%PHPBIN%" if "%PHP_PEAR_PHP_BIN%" neq "" goto USE_PEAR_PATH
10+
GOTO RUN
11+
:USE_PEAR_PATH
12+
set PHPBIN=%PHP_PEAR_PHP_BIN%
13+
:RUN
14+
"%PHPBIN%" "@bin_dir@\phpcs" %*

package.xml

Lines changed: 9 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -110,20 +110,18 @@ http://pear.php.net/dtd/package-2.0.xsd">
110110
<file baseinstalldir="" name="phpcs" role="script">
111111
<tasks:replace from="/usr/bin/env php" to="php_bin" type="pear-config" />
112112
</file>
113-
<!--
114-
<file baseinstalldir="" name="phpcs-svn-pre-commit" role="script">
115-
<tasks:replace from="@php_bin@" to="php_bin" type="pear-config" />
116-
<tasks:replace from="@package_version@" to="version" type="package-info" />
117-
</file>
118113
<file baseinstalldir="" name="phpcs.bat" role="script">
119114
<tasks:replace from="@php_bin@" to="php_bin" type="pear-config" />
120115
<tasks:replace from="@bin_dir@" to="bin_dir" type="pear-config" />
121-
<tasks:replace from="@php_dir@" to="php_dir" type="pear-config" />
122116
</file>
123117
<file baseinstalldir="" name="phpcbf.bat" role="script">
124118
<tasks:replace from="@php_bin@" to="php_bin" type="pear-config" />
125119
<tasks:replace from="@bin_dir@" to="bin_dir" type="pear-config" />
126-
<tasks:replace from="@php_dir@" to="php_dir" type="pear-config" />
120+
</file>
121+
<!--
122+
<file baseinstalldir="" name="phpcs-svn-pre-commit" role="script">
123+
<tasks:replace from="@php_bin@" to="php_bin" type="pear-config" />
124+
<tasks:replace from="@package_version@" to="version" type="package-info" />
127125
</file>
128126
-->
129127
</dir>
@@ -1508,10 +1506,8 @@ http://pear.php.net/dtd/package-2.0.xsd">
15081506
<filelist>
15091507
<install as="phpcs" name="bin/phpcs" />
15101508
<install as="phpcbf" name="bin/phpcbf" />
1511-
<!--
1512-
<install as="phpcs.bat" name="scripts/phpcs.bat" />
1513-
<install as="phpcbf.bat" name="scripts/phpcbf.bat" />
1514-
-->
1509+
<install as="phpcs.bat" name="bin/phpcs.bat" />
1510+
<install as="phpcbf.bat" name="bin/phpcbf.bat" />
15151511
<install as="README" name="README.md" />
15161512
<install as="CONTRIBUTING" name="CONTRIBUTING.md" />
15171513
<install as="LICENCE" name="licence.txt" />
@@ -1540,10 +1536,8 @@ http://pear.php.net/dtd/package-2.0.xsd">
15401536
<install as="CodeSniffer/Core/File/GetMethodParametersTest.php" name="tests/Core/File/GetMethodParametersTest.php" />
15411537
<install as="CodeSniffer/Standards/AllSniffs.php" name="tests/Standards/AllSniffs.php" />
15421538
<install as="CodeSniffer/Standards/AbstractSniffUnitTest.php" name="tests/Standards/AbstractSniffUnitTest.php" />
1543-
<!--
1544-
<ignore name="scripts/phpcs.bat" />
1545-
<ignore name="scripts/phpcbf.bat" />
1546-
-->
1539+
<ignore name="bin/phpcs.bat" />
1540+
<ignore name="bin/phpcbf.bat" />
15471541
</filelist>
15481542
</phprelease>
15491543
<changelog>

scripts/phpcs.bat

Lines changed: 0 additions & 21 deletions
This file was deleted.

0 commit comments

Comments
 (0)