How to use PHP_CodeSniffer with XAMPP?

不问归期 提交于 2019-12-07 06:36:32

问题


I am running XAMPP with windows XP. I just download PHP_CodeSniffer and cannot figure out how to run it.

Thank you


回答1:


The documentation has it all.

EDIT:

The first line of phpcs is:

#!@php_bin@

you need to replace @php_bin@ with correct path to php to make a meaningful shebang as(In linux):

#!/usr/bin/php

Since windows does not have the concept of shebang, you can delete the first line of phpcsand then run it as:

C:\>path\to\php\bin\php.exe path\to\phpcs path\to\file\to\analyze


来源:https://stackoverflow.com/questions/3611865/how-to-use-php-codesniffer-with-xampp

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!