Home
Docs
GitHub
Pricing
Blog
Log In

Run Sandworm Audit for your App

Get started
Hold on, we're currently generating a fresh version of this report
Generated on May 10, 2024 via composer

squizlabs/php_codesniffer 3.9.0

PHP_CodeSniffer tokenizes PHP, JavaScript and CSS files and detects violations of a defined set of coding standards.
Package summary
Share
0
issues
1
license
1
BSD-3-Clause
Package created
6 Nov 2012
Version published
16 Feb 2024
Maintainers
2
Total deps
1
Direct deps
0
License
BSD-3-Clause

Issues

0
This package has no issues

Licenses

BSD 3-Clause "New" or "Revised" License

Permissive
OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
commercial-use
modify
distribute
place-warranty
Cannot
use-trademark
hold-liable
Must
include-copyright
include-license
1 Packages, Including:
squizlabs/php_codesniffer@3.9.0
Disclaimer

This deed highlights only some of the key features and terms of the actual license. It is not a license and has no legal value. You should carefully review all of the terms and conditions of the actual license before using the licensed material.

Sandworm is not a law firm and does not provide legal services. Distributing, displaying, or linking to this deed or the license that it summarizes does not create a lawyer-client or any other relationship.

Direct Dependencies

0
All Dependencies CSV
β“˜ This is a list of squizlabs/php_codesniffer 's direct dependencies. Data on all dependencies, including transitive ones, is available via CSV download.
NameVersionSizeLicenseTypeVulnerabilities

Visualizations

Frequently Asked Questions

What does squizlabs/php_codesniffer do?

The Squizlabs/PHP_CodeSniffer is a fantastic development tool known for maintaining the cleanliness and consistency of your code. In essence, it tokenizes PHP, JavaScript, and CSS files and detects violations of a predefined set of coding standards. Incorporating two PHP scripts - the 'phpcs' script that detects coding standard violations, and the 'phpcbf' script that automatically corrects such violations, PHP_CodeSniffer provides an unparalleled edge to the current development practices.

How do you use squizlabs/php_codesniffer?

To get started with PHP_CodeSniffer, you can simply download the Phar files for each of the commands using curl or wget. You can use Composer, Phive, PEAR or Git to install it. For Composer, the command would be "composer global require 'squizlabs/php_codesniffer=*'" or you can include it in your composer.json file. With Phive, you install PHP_CodeSniffer as a project tool using "phive install phpcs" and "phive install phpcbf". You can also install it with PEAR installer after ensuring you have installed PEAR, or download the source and run the commands directly from the Git clone. The default coding standard used by PHP_CodeSniffer is the PEAR coding standard. To check a file or a directory against the PEAR coding standard, specify the file or directory's location with the command "phpcs /path/to/code/myfile.php" or "phpcs /path/to/code-directory". For checking against the PSR-12 coding standard, use the --standard command line argument with the command "phpcs --standard=PSR12 /path/to/code-directory".

# here's an example of how to check a file against the PEAR coding standard
phpcs /path/to/code/myfile.php

# if you wish to check against the PSR-12 coding standard
phpcs --standard=PSR12 /path/to/code-directory

Where are the squizlabs/php_codesniffer docs?

The detailed documentation for PHP_CodeSniffer is readily available on their GitHub Wiki page. You can access everything from configuration options, coding standard specifics to advanced usage tips on this page. Any issues, bug reports or feature requests can be submitted on the GitHub Issue Tracker for the project. For anyone eager to contribute to the project, you can refer to the CONTRIBUTING.md file for comprehensive information.