├── .gitignore
├── resources
└── stubs
│ ├── phpcs.xml.stub
│ └── pre-commit-hook.stub
├── src
└── LaravelPhpcsServiceProvider.php
├── LICENSE.md
├── composer.json
├── CHANGELOG.md
├── CONTRIBUTING.md
├── README.md
├── phpcs.xml
└── composer.lock
/.gitignore:
--------------------------------------------------------------------------------
1 | !.gitignore
2 | vendor
3 |
--------------------------------------------------------------------------------
/resources/stubs/phpcs.xml.stub:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | ./app
6 | ./config
7 | ./resources
8 | ./routes
9 | ./tests
10 |
11 |
12 |
13 |
--------------------------------------------------------------------------------
/src/LaravelPhpcsServiceProvider.php:
--------------------------------------------------------------------------------
1 | app->runningInConsole()) {
15 | $this->publishes([
16 | __DIR__.'/../resources/stubs/phpcs.xml.stub' => base_path('phpcs.xml'),
17 | ], 'ruleset');
18 |
19 | $this->publishes([
20 | __DIR__.'/../resources/stubs/pre-commit-hook.stub' => base_path('.git/hooks/pre-commit'),
21 | ], 'hook');
22 | }
23 | }
24 | }
25 |
--------------------------------------------------------------------------------
/resources/stubs/pre-commit-hook.stub:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env bash
2 |
3 | # get bash colors and styles here:
4 | # http://misc.flogisoft.com/bash/tip_colors_and_formatting
5 | C_RESET='\e[0m'
6 | C_RED='\e[31m'
7 | C_GREEN='\e[32m'
8 | C_YELLOW='\e[33m'
9 |
10 | function __run() #(step, name, cmd)
11 | {
12 | local color output exitcode
13 |
14 | printf "${C_YELLOW}[%s]${C_RESET} %-20s" "$1" "$2"
15 | output=$(eval "$3" 2>&1)
16 | exitcode=$?
17 |
18 | if [[ 0 == $exitcode || 130 == $exitcode ]]; then
19 | echo -e "${C_GREEN}OK!${C_RESET}"
20 | else
21 | echo -e "${C_RED}NOK!${C_RESET}\n\n$output"
22 | exit 1
23 | fi
24 | }
25 |
26 | modified="git diff --diff-filter=M --name-only --cached | grep \".php$\""
27 | ignore="resources/lang,resources/views,bootstrap/helpers,database/migrations,bin"
28 | phpcs="vendor/bin/phpcs --report=code --colors --report-width=80 --ignore=${ignore}"
29 |
30 | __run "1/1" "code sniffer" "${modified} | xargs -r ${phpcs}"
31 | # __run "2/3" "php lint" "${modified} | xargs -r php -l"
32 | # __run "3/3" "phpstan" "${modified} | xargs -r vendor/bin/phpstan analyse"
33 |
--------------------------------------------------------------------------------
/LICENSE.md:
--------------------------------------------------------------------------------
1 | MIT License
2 |
3 | Copyright (c) Eduar Bastidas
4 |
5 | Permission is hereby granted, free of charge, to any person obtaining a copy
6 | of this software and associated documentation files (the "Software"), to deal
7 | in the Software without restriction, including without limitation the rights
8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9 | copies of the Software, and to permit persons to whom the Software is
10 | furnished to do so, subject to the following conditions:
11 |
12 | The above copyright notice and this permission notice shall be included in all
13 | copies or substantial portions of the Software.
14 |
15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21 | SOFTWARE.
--------------------------------------------------------------------------------
/composer.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "mreduar/laravel-phpcs",
3 | "description": "PHP Codesniffer ruleset to follow Laravel's coding style",
4 | "keywords": [
5 | "mreduar",
6 | "laravel-phpcs",
7 | "phpcs",
8 | "php",
9 | "coding-style",
10 | "coding sniffer",
11 | "coding-standard"
12 | ],
13 | "homepage": "https://github.com/mreduar/laravel-phpcs",
14 | "license": "MIT",
15 | "type": "library",
16 | "authors": [
17 | {
18 | "name": "Eduar Bastidas",
19 | "email": "eduarbatidas10@gmail.com",
20 | "role": "Developer"
21 | }
22 | ],
23 | "require": {
24 | "php": "^7.4|^8.0",
25 | "slevomat/coding-standard": "^8.0",
26 | "squizlabs/php_codesniffer": "^3.7"
27 | },
28 | "autoload": {
29 | "psr-4": {
30 | "Mreduar\\LaravelPhpcs\\": "src"
31 | }
32 | },
33 | "config": {
34 | "sort-packages": true,
35 | "allow-plugins": {
36 | "dealerdirect/phpcodesniffer-composer-installer": true
37 | }
38 | },
39 | "extra": {
40 | "laravel": {
41 | "providers": [
42 | "Mreduar\\LaravelPhpcs\\LaravelPhpcsServiceProvider"
43 | ]
44 | }
45 | }
46 | }
47 |
--------------------------------------------------------------------------------
/CHANGELOG.md:
--------------------------------------------------------------------------------
1 | # Changelog
2 |
3 | All notable changes to `laravel-phpcs` will be documented in this file
4 |
5 | ## 1.8.1 - 2022-11-02
6 | - Modified rule to allow empty catches.
7 |
8 | ## 1.8.0 - 2022-10-20
9 | - Added rule to disallow the use of variables without camel case.
10 |
11 | ## 1.7.2 - 2022-10-17
12 | - Multiple parameters are now supported on the same line in multi-line functions.
13 |
14 | ## 1.7.1 - 2022-06-20
15 | - Updated slevomat/coding-standard to estable version.
16 |
17 | ## 1.7.0 - 2022-06-13
18 | - Added support to enums.
19 | - Updated php_codesniffer to 3.7.
20 | - Updated slevomat/coding-standard to dev-php81 to support enums.
21 |
22 | ## 1.6.0 - 2022-05-20
23 |
24 | - [Custom sniffs](https://github.com/slevomat/coding-standard) have been added to improve the Laravel standard.
25 | - Added `SlevomatCodingStandard.Namespaces.UnusedUses` to avoid unused uses.
26 | - Added `SlevomatCodingStandard.Namespaces.UseFromSameNamespace` to avoid uses from same namespace.
27 | - Added `SlevomatCodingStandard.Namespaces.AlphabeticallySortedUses` for the imports to be sorted alphabetically.
28 | - Added `SlevomatCodingStandard.Namespaces.FullyQualifiedClassNameInAnnotation` to enforces fully qualified names of classes and interfaces in phpDocs.
29 | - Added `SlevomatCodingStandard.PHP.UselessSemicolon` to avoid useless semicolons.
30 | - Added `SlevomatCodingStandard.Classes.MethodSpacing` to check that there is a blank line between the methods.
31 | - Added `SlevomatCodingStandard.Functions.ArrowFunctionDeclaration` to check that the number of spaces after and before the arrow is correct.
32 | - Added `SlevomatCodingStandard.Files.TypeNameMatchesFileName` to check that the type name matches the file name.
33 |
34 | ## 1.5.0 - 2022-04-05
35 |
36 | - Added `Generic.NamingConventions.CamelCapsFunctionName` to avoid function names with `snake_case`
37 | - Added new rule `Generic.Formatting.SpaceAfterNot`
38 |
39 | ## 1.4.0 - 2022-03-15
40 |
41 | - Added rule to prefer single quotation marks
42 |
43 | ## 1.3.1 - 2022-02-20
44 |
45 | - Now the Providers code is checked
46 |
47 | ## 1.3.0 - 2022-02-12
48 |
49 | - Deleted illuminate/support dependency to make the package compatible with any version of Laravel
50 |
51 | ## 1.2.0 - 2022-01-27
52 |
53 | - Added optional git pre-hook to validate with phpcs before every commit.
54 |
55 | ## 1.1.0 - 2022-01-26
56 |
57 | - Excluded route files for Generic.CodeAnalysis.UnusedFunctionParameter rule.
58 |
59 | ## 1.0.0 - 2022-01-25
60 |
61 | - initial release
62 |
--------------------------------------------------------------------------------
/CONTRIBUTING.md:
--------------------------------------------------------------------------------
1 | # Contributing
2 |
3 | Contributions are **welcome** and will be fully **credited**.
4 |
5 | Please read and understand the contribution guide before creating an issue or pull request.
6 |
7 | ## Etiquette
8 |
9 | This project is open source, and as such, the maintainers give their free time to build and maintain the source code
10 | held within. They make the code freely available in the hope that it will be of use to other developers. It would be
11 | extremely unfair for them to suffer abuse or anger for their hard work.
12 |
13 | Please be considerate towards maintainers when raising issues or presenting pull requests. Let's show the
14 | world that developers are civilized and selfless people.
15 |
16 | It's the duty of the maintainer to ensure that all submissions to the project are of sufficient
17 | quality to benefit the project. Many developers have different skillsets, strengths, and weaknesses. Respect the maintainer's decision, and do not be upset or abusive if your submission is not used.
18 |
19 | ## Viability
20 |
21 | When requesting or submitting new features, first consider whether it might be useful to others. Open
22 | source projects are used by many developers, who may have entirely different needs to your own. Think about
23 | whether or not your feature is likely to be used by other users of the project.
24 |
25 | ## Procedure
26 |
27 | Before filing an issue:
28 |
29 | - Attempt to replicate the problem, to ensure that it wasn't a coincidental incident.
30 | - Check to make sure your feature suggestion isn't already present within the project.
31 | - Check the pull requests tab to ensure that the bug doesn't have a fix in progress.
32 | - Check the pull requests tab to ensure that the feature isn't already in progress.
33 |
34 | Before submitting a pull request:
35 |
36 | - Check the codebase to ensure that your feature doesn't already exist.
37 | - Check the pull requests to ensure that another person hasn't already submitted the feature or fix.
38 |
39 | ## Requirements
40 |
41 | If the project maintainer has any additional requirements, you will find them listed here.
42 |
43 | - **Document any change in behaviour** - Make sure the `README.md` and any other relevant documentation are kept up-to-date.
44 |
45 | - **One pull request per feature** - If you want to do more than one thing, send multiple pull requests.
46 |
47 | - **Send coherent history** - Make sure each individual commit in your pull request is meaningful. If you had to make multiple intermediate commits while developing, please [squash them](https://www.git-scm.com/book/en/v2/Git-Tools-Rewriting-History#Changing-Multiple-Commit-Messages) before submitting.
48 |
49 | **Happy coding**!
50 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # PHP Codesniffer ruleset to follow Laravel's coding style
2 |
3 | [](LICENSE.md)
4 | [](/compare)
5 |
6 | [php codesniffer](https://github.com/squizlabs/PHP_CodeSniffer/wiki/Annotated-Ruleset) ruleset for laravel or any other php projects.
7 |
8 | ## Installation
9 | **[*]** Install using composer
10 |
11 | ```bash
12 | composer require mreduar/laravel-phpcs --dev
13 | ```
14 |
15 | **[*]** Install manually
16 |
17 | 1. Copy the `phpcs.xml` file into your project root.
18 | 2. Descoment lines `app` and the others in `phpcs.xml` file.
19 | 3. Because this package uses third party standards that are not in phpcs you need to install these package.
20 | 1. `composer require slevomat/coding-standard`
21 | 4. Run `phpcs .` to check your project.
22 |
23 | ## Usage
24 |
25 | ### Enabling the rules
26 |
27 | > Only neccesary if you installed as a package using composer!
28 |
29 | `php artisan vendor:publish --provider="Mreduar\LaravelPhpcs\LaravelPhpcsServiceProvider" --tag="ruleset"`
30 |
31 | This will publish to your root directory the following file
32 |
33 | ```xml
34 |
35 |
36 |
37 |
38 | ./app
39 | ./config
40 | ./resources
41 | ./routes
42 | ./tests
43 |
44 |
45 |
46 | ```
47 |
48 | Optionally you can also publish a git hook that will help you to never overlook smelly code.
49 |
50 | `php artisan vendor:publish --provider="Mreduar\LaravelPhpcs\LaravelPhpcsServiceProvider" --tag="hook"`
51 |
52 | The file will be published in its root directory `.git/hooks/pre-commit`
53 | So every time you try to commit `phpcs` will first check that you have everything correct.
54 |
55 | ```bash
56 | $ git commit -m "test"
57 | [1/1] code sniffer OK!
58 | [master a6133d7] test
59 | 1 file changed, 1 insertion(+), 1 deletion(-)
60 | ```
61 |
62 | if you have any errors the commit will be cancelled.
63 |
64 |
65 | ### Sniffing code
66 | Use php CodeSniffer commands, pointed towards your xml file, to sniff the code
67 | using the new ruleset.
68 |
69 | `vendor/bin/phpcs`
70 | `vendor/bin/phpcbf`
71 |
72 | #### Sniffing code in PHPStorm
73 |
74 | See [PHP Code Sniffer in PhpStorm](https://confluence.jetbrains.com/display/PhpStorm/PHP+Code+Sniffer+in+PhpStorm) on how to set up CodeSniffer in PHPStorm.
75 |
76 | #### Sniffing code Visual Studio Code
77 |
78 | See [PHP Sniffer by wongjn](https://marketplace.visualstudio.com/items?itemName=wongjn.php-sniffer) or other [phpcs](https://marketplace.visualstudio.com/search?term=phpcs&target=VSCode&category=All%20categories&sortBy=Relevance) plugins for more information about PHP Code Sniffer in Visual Studio Code.
79 |
80 | --------------------------------------------------------------------------------
81 |
82 |
83 | ## Contributing
84 |
85 | All changes that makes the sniffer more accurate towards _Laravel_'s coding standard
86 | is always highly appreciated and welcome.
87 |
88 | Please see [CONTRIBUTING](CONTRIBUTING.md) for more details.
89 |
90 | ## Credits
91 |
92 | - [All Contributors](../../contributors)
93 |
94 | ## License
95 |
96 | The MIT License (MIT). Please see [License File](LICENSE.md) for more information.
97 |
--------------------------------------------------------------------------------
/phpcs.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | PHP Codesniffer ruleset to follow Laravel's coding style
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 | /app/Http/Resources/*\.php
15 | /routes/*\.php
16 | 0
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 | */tests
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 | */artisan
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
81 | *.php
82 |
83 |
84 | database/*
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 |
107 |
108 |
109 |
110 |
111 |
112 |
113 |
114 |
115 |
116 |
117 |
118 |
119 |
120 |
121 |
122 |
123 |
124 |
125 |
126 |
127 |
128 |
129 |
130 |
131 |
132 |
133 |
134 |
135 |
136 |
137 |
138 |
139 |
140 |
141 |
142 |
143 |
144 |
145 |
146 |
147 |
148 |
149 |
150 |
151 |
152 |
153 |
154 |
155 |
156 |
157 |
158 |
159 |
160 |
161 |
162 |
163 |
164 |
165 |
166 |
167 |
168 |
169 |
170 |
171 |
172 |
173 |
174 |
175 |
176 |
177 |
178 |
179 |
180 |
181 |
182 |
183 |
184 | /database/schema/*
185 | /database/migrations/*
186 |
187 |
188 |
194 |
195 | */.phpstorm.meta.php
196 | */_ide_helper.php
197 | */cache/*
198 | */config/*
199 | */database/*
200 | */docs/*
201 | */migrations/*
202 | */storage/*
203 | */public/index.php
204 | */resources/lang/*
205 | */vendor/*
206 | */*.js
207 | */*.css
208 | */*.xml
209 | */*.blade.php
210 | */autoload.php
211 | */Console/Kernel.php
212 | */Exceptions/Handler.php
213 | */Http/Kernel.php
214 |
215 |
216 |
217 |
218 |
219 |
--------------------------------------------------------------------------------
/composer.lock:
--------------------------------------------------------------------------------
1 | {
2 | "_readme": [
3 | "This file locks the dependencies of your project to a known state",
4 | "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
5 | "This file is @generated automatically"
6 | ],
7 | "content-hash": "00e9f506a4b55c87e35197be52d00ea9",
8 | "packages": [
9 | {
10 | "name": "dealerdirect/phpcodesniffer-composer-installer",
11 | "version": "v0.7.2",
12 | "source": {
13 | "type": "git",
14 | "url": "https://github.com/Dealerdirect/phpcodesniffer-composer-installer.git",
15 | "reference": "1c968e542d8843d7cd71de3c5c9c3ff3ad71a1db"
16 | },
17 | "dist": {
18 | "type": "zip",
19 | "url": "https://api.github.com/repos/Dealerdirect/phpcodesniffer-composer-installer/zipball/1c968e542d8843d7cd71de3c5c9c3ff3ad71a1db",
20 | "reference": "1c968e542d8843d7cd71de3c5c9c3ff3ad71a1db",
21 | "shasum": ""
22 | },
23 | "require": {
24 | "composer-plugin-api": "^1.0 || ^2.0",
25 | "php": ">=5.3",
26 | "squizlabs/php_codesniffer": "^2.0 || ^3.1.0 || ^4.0"
27 | },
28 | "require-dev": {
29 | "composer/composer": "*",
30 | "php-parallel-lint/php-parallel-lint": "^1.3.1",
31 | "phpcompatibility/php-compatibility": "^9.0"
32 | },
33 | "type": "composer-plugin",
34 | "extra": {
35 | "class": "Dealerdirect\\Composer\\Plugin\\Installers\\PHPCodeSniffer\\Plugin"
36 | },
37 | "autoload": {
38 | "psr-4": {
39 | "Dealerdirect\\Composer\\Plugin\\Installers\\PHPCodeSniffer\\": "src/"
40 | }
41 | },
42 | "notification-url": "https://packagist.org/downloads/",
43 | "license": [
44 | "MIT"
45 | ],
46 | "authors": [
47 | {
48 | "name": "Franck Nijhof",
49 | "email": "franck.nijhof@dealerdirect.com",
50 | "homepage": "http://www.frenck.nl",
51 | "role": "Developer / IT Manager"
52 | },
53 | {
54 | "name": "Contributors",
55 | "homepage": "https://github.com/Dealerdirect/phpcodesniffer-composer-installer/graphs/contributors"
56 | }
57 | ],
58 | "description": "PHP_CodeSniffer Standards Composer Installer Plugin",
59 | "homepage": "http://www.dealerdirect.com",
60 | "keywords": [
61 | "PHPCodeSniffer",
62 | "PHP_CodeSniffer",
63 | "code quality",
64 | "codesniffer",
65 | "composer",
66 | "installer",
67 | "phpcbf",
68 | "phpcs",
69 | "plugin",
70 | "qa",
71 | "quality",
72 | "standard",
73 | "standards",
74 | "style guide",
75 | "stylecheck",
76 | "tests"
77 | ],
78 | "support": {
79 | "issues": "https://github.com/dealerdirect/phpcodesniffer-composer-installer/issues",
80 | "source": "https://github.com/dealerdirect/phpcodesniffer-composer-installer"
81 | },
82 | "time": "2022-02-04T12:51:07+00:00"
83 | },
84 | {
85 | "name": "phpstan/phpdoc-parser",
86 | "version": "1.6.3",
87 | "source": {
88 | "type": "git",
89 | "url": "https://github.com/phpstan/phpdoc-parser.git",
90 | "reference": "4a07085f74cb1f3fc7103efa537d9f00ebb74ec7"
91 | },
92 | "dist": {
93 | "type": "zip",
94 | "url": "https://api.github.com/repos/phpstan/phpdoc-parser/zipball/4a07085f74cb1f3fc7103efa537d9f00ebb74ec7",
95 | "reference": "4a07085f74cb1f3fc7103efa537d9f00ebb74ec7",
96 | "shasum": ""
97 | },
98 | "require": {
99 | "php": "^7.2 || ^8.0"
100 | },
101 | "require-dev": {
102 | "php-parallel-lint/php-parallel-lint": "^1.2",
103 | "phpstan/extension-installer": "^1.0",
104 | "phpstan/phpstan": "^1.5",
105 | "phpstan/phpstan-phpunit": "^1.1",
106 | "phpstan/phpstan-strict-rules": "^1.0",
107 | "phpunit/phpunit": "^9.5",
108 | "symfony/process": "^5.2"
109 | },
110 | "type": "library",
111 | "autoload": {
112 | "psr-4": {
113 | "PHPStan\\PhpDocParser\\": [
114 | "src/"
115 | ]
116 | }
117 | },
118 | "notification-url": "https://packagist.org/downloads/",
119 | "license": [
120 | "MIT"
121 | ],
122 | "description": "PHPDoc parser with support for nullable, intersection and generic types",
123 | "support": {
124 | "issues": "https://github.com/phpstan/phpdoc-parser/issues",
125 | "source": "https://github.com/phpstan/phpdoc-parser/tree/1.6.3"
126 | },
127 | "time": "2022-06-14T11:40:08+00:00"
128 | },
129 | {
130 | "name": "slevomat/coding-standard",
131 | "version": "8.0.0",
132 | "source": {
133 | "type": "git",
134 | "url": "https://github.com/slevomat/coding-standard.git",
135 | "reference": "84cc1693467996d0fc0838d4d4594eb9890ab295"
136 | },
137 | "dist": {
138 | "type": "zip",
139 | "url": "https://api.github.com/repos/slevomat/coding-standard/zipball/84cc1693467996d0fc0838d4d4594eb9890ab295",
140 | "reference": "84cc1693467996d0fc0838d4d4594eb9890ab295",
141 | "shasum": ""
142 | },
143 | "require": {
144 | "dealerdirect/phpcodesniffer-composer-installer": "^0.6.2 || ^0.7",
145 | "php": "^7.2 || ^8.0",
146 | "phpstan/phpdoc-parser": "^1.6.2",
147 | "squizlabs/php_codesniffer": "^3.7.0"
148 | },
149 | "require-dev": {
150 | "phing/phing": "2.17.3",
151 | "php-parallel-lint/php-parallel-lint": "1.3.2",
152 | "phpstan/phpstan": "1.4.10|1.7.14",
153 | "phpstan/phpstan-deprecation-rules": "1.0.0",
154 | "phpstan/phpstan-phpunit": "1.0.0|1.1.1",
155 | "phpstan/phpstan-strict-rules": "1.2.3",
156 | "phpunit/phpunit": "7.5.20|8.5.21|9.5.20"
157 | },
158 | "type": "phpcodesniffer-standard",
159 | "extra": {
160 | "branch-alias": {
161 | "dev-master": "7.x-dev"
162 | }
163 | },
164 | "autoload": {
165 | "psr-4": {
166 | "SlevomatCodingStandard\\": "SlevomatCodingStandard"
167 | }
168 | },
169 | "notification-url": "https://packagist.org/downloads/",
170 | "license": [
171 | "MIT"
172 | ],
173 | "description": "Slevomat Coding Standard for PHP_CodeSniffer complements Consistence Coding Standard by providing sniffs with additional checks.",
174 | "support": {
175 | "issues": "https://github.com/slevomat/coding-standard/issues",
176 | "source": "https://github.com/slevomat/coding-standard/tree/8.0.0"
177 | },
178 | "funding": [
179 | {
180 | "url": "https://github.com/kukulich",
181 | "type": "github"
182 | },
183 | {
184 | "url": "https://tidelift.com/funding/github/packagist/slevomat/coding-standard",
185 | "type": "tidelift"
186 | }
187 | ],
188 | "time": "2022-06-17T13:13:47+00:00"
189 | },
190 | {
191 | "name": "squizlabs/php_codesniffer",
192 | "version": "3.7.1",
193 | "source": {
194 | "type": "git",
195 | "url": "https://github.com/squizlabs/PHP_CodeSniffer.git",
196 | "reference": "1359e176e9307e906dc3d890bcc9603ff6d90619"
197 | },
198 | "dist": {
199 | "type": "zip",
200 | "url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/1359e176e9307e906dc3d890bcc9603ff6d90619",
201 | "reference": "1359e176e9307e906dc3d890bcc9603ff6d90619",
202 | "shasum": ""
203 | },
204 | "require": {
205 | "ext-simplexml": "*",
206 | "ext-tokenizer": "*",
207 | "ext-xmlwriter": "*",
208 | "php": ">=5.4.0"
209 | },
210 | "require-dev": {
211 | "phpunit/phpunit": "^4.0 || ^5.0 || ^6.0 || ^7.0"
212 | },
213 | "bin": [
214 | "bin/phpcs",
215 | "bin/phpcbf"
216 | ],
217 | "type": "library",
218 | "extra": {
219 | "branch-alias": {
220 | "dev-master": "3.x-dev"
221 | }
222 | },
223 | "notification-url": "https://packagist.org/downloads/",
224 | "license": [
225 | "BSD-3-Clause"
226 | ],
227 | "authors": [
228 | {
229 | "name": "Greg Sherwood",
230 | "role": "lead"
231 | }
232 | ],
233 | "description": "PHP_CodeSniffer tokenizes PHP, JavaScript and CSS files and detects violations of a defined set of coding standards.",
234 | "homepage": "https://github.com/squizlabs/PHP_CodeSniffer",
235 | "keywords": [
236 | "phpcs",
237 | "standards"
238 | ],
239 | "support": {
240 | "issues": "https://github.com/squizlabs/PHP_CodeSniffer/issues",
241 | "source": "https://github.com/squizlabs/PHP_CodeSniffer",
242 | "wiki": "https://github.com/squizlabs/PHP_CodeSniffer/wiki"
243 | },
244 | "time": "2022-06-18T07:21:10+00:00"
245 | }
246 | ],
247 | "packages-dev": [],
248 | "aliases": [],
249 | "minimum-stability": "stable",
250 | "stability-flags": [],
251 | "prefer-stable": false,
252 | "prefer-lowest": false,
253 | "platform": {
254 | "php": "^7.4|^8.0"
255 | },
256 | "platform-dev": [],
257 | "plugin-api-version": "2.2.0"
258 | }
259 |
--------------------------------------------------------------------------------