- Notifications
You must be signed in to change notification settings - Fork45
adding new php tool docs#419
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Merged
Uh oh!
There was an error while loading.Please reload this page.
Merged
Changes fromall commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Uh oh!
There was an error while loading.Please reload this page.
Jump to
Jump to file
Failed to load files.
Loading
Uh oh!
There was an error while loading.Please reload this page.
Diff view
Diff view
There are no files selected for viewing
12 changes: 12 additions & 0 deletionsdocs/changelog.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters
4 changes: 3 additions & 1 deletiondocs/tools/list.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters
47 changes: 47 additions & 0 deletionsdocs/tools/phpcs.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
--- | ||
title: PHPCS | ||
sidebar_label: PHPCS | ||
description: CodeRabbit's guide to PHPCS. | ||
--- | ||
```mdx-code-block | ||
import ProPlanNotice from '@site/src/components/ProPlanNotice.mdx'; | ||
<ProPlanNotice /> | ||
``` | ||
[PHPCS](https://github.com/squizlabs/PHP_CodeSniffer) (PHP CodeSniffer) is a development tool that ensures your code conforms to a coding standard. It is an essential tool for any development team that wants to ensure their code is consistent and follows best practices. | ||
## Files | ||
PHPCS will run on files with the following extensions: | ||
- `.php` | ||
## Features | ||
PHPCS can detect and fix various coding standard violations including: | ||
- **PSR Standards**: Enforces PSR-1, PSR-2, PSR-12, and other coding standards | ||
- **Custom Standards**: Supports custom coding standards and rules | ||
- **Auto-fixing**: Can automatically fix many coding standard violations | ||
- **Custom Rules**: Allows creation of custom sniff rules | ||
- **Multiple Standards**: Can enforce multiple coding standards simultaneously | ||
## Popular Standards | ||
PHPCS supports many coding standards including: | ||
- **PSR-1**: Basic Coding Standard | ||
- **PSR-2**: Coding Style Guide | ||
- **PSR-12**: Extended Coding Style | ||
- **Squiz**: Squiz Labs coding standard | ||
- **PEAR**: PEAR coding standard | ||
- **Zend**: Zend Framework coding standard | ||
## Links | ||
- [PHPCS GitHub Repository](https://github.com/squizlabs/PHP_CodeSniffer) | ||
- [PHPCS Documentation](https://github.com/squizlabs/PHP_CodeSniffer/wiki) | ||
- [Available Coding Standards](https://github.com/squizlabs/PHP_CodeSniffer/wiki/Coding-Standards) | ||
- [Creating Custom Standards](https://github.com/squizlabs/PHP_CodeSniffer/wiki/Coding-Standards#creating-a-coding-standard) |
37 changes: 37 additions & 0 deletionsdocs/tools/phpmd.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
--- | ||
title: PHPMD | ||
sidebar_label: PHPMD | ||
description: CodeRabbit's guide to PHPMD. | ||
--- | ||
```mdx-code-block | ||
import ProPlanNotice from '@site/src/components/ProPlanNotice.mdx'; | ||
<ProPlanNotice /> | ||
``` | ||
[PHPMD](https://phpmd.org/) (PHP Mess Detector) is a static analysis tool for PHP that detects potential problems in your code such as possible bugs, suboptimal code, overcomplicated expressions, and unused parameters, variables, methods, and classes. | ||
## Files | ||
PHPMD will run on files with the following extensions: | ||
- `.php` | ||
## Features | ||
PHPMD can detect various code quality issues including: | ||
- **Clean Code Rules**: Detects code smells and violations of clean code principles | ||
- **Controversial Rules**: Identifies potentially problematic code patterns | ||
- **Design Rules**: Finds design-related issues and architectural problems | ||
- **Naming Rules**: Checks for naming convention violations | ||
- **Unused Code Rules**: Detects unused variables, parameters, methods, and classes | ||
- **Size Rules**: Identifies overly complex methods and classes | ||
## Links | ||
- [PHPMD Official Website](https://phpmd.org/) | ||
- [PHPMD GitHub Repository](https://github.com/phpmd/phpmd) | ||
- [PHPMD Documentation](https://phpmd.org/documentation/index.html) | ||
- [Available Rules](https://phpmd.org/rules/index.html) |
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.