Composer : PHP 환경에서 사용하는 의존성 관리 도구
설치 => https://getcomposer.org/download/
C:\Users\Administrator>composer
Composer version 1.6.4 2018-04-13 12:04:24
Usage: command [options] [arguments]
Options:
-h, --help Display this help message
-q, --quiet Do not output any message
-V, --version Display this application version
--ansi Force ANSI output
--no-ansi Disable ANSI output
-n, --no-interaction Do not ask any interactive question
--profile Display timing and memory usage information
--no-plugins Whether to disable plugins.
c:\APMorg\Apache24\htdocs>composer global require squizlabs/php_codesniffer
Changed current directory to C:/Users/Administrator/AppData/Roaming/Composer
Using version ^3.2 for squizlabs/php_codesniffer
./composer.json has been created
Loading composer repositories with package information
Updating dependencies (including require-dev)
Package operations: 1 install, 0 updates, 0 removals
- Installing squizlabs/php_codesniffer (3.2.3): Downloading (100%)
Writing lock file
Generating autoload files
c:\APMorg\Apache24\htdocs>
C:\APMorg\Apache24\htdocs>composer require --dev squizlabs/php_codesniffer
Using version ^3.2 for squizlabs/php_codesniffer
./composer.json has been created
Loading composer repositories with package information
Updating dependencies (including require-dev)
Package operations: 1 install, 0 updates, 0 removals
- Installing squizlabs/php_codesniffer (3.2.3): Loading from cache
Writing lock file
Generating autoload files
phpcs에서 invalid라 warning하는 건
주석 / 문법오류 / 함수사용시 패턴 / 들여쓰기등을 가이드 해주면서 일괄적인 코딩패턴을 유지할 수 있게 해준다. warning없애려고 하다보니 코드가 깔끔해졌다. => 가독성 좋아짐
참고 ) 주석관련 : https://github.com/squizlabs/PHP_CodeSniffer/issues/258