-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Big code cleanning CS fixer php stan
- Loading branch information
1 parent
4a699f4
commit 5daedfa
Showing
40 changed files
with
2,346 additions
and
2,197 deletions.
There are no files selected for viewing
This file contains 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,14 @@ | ||
# EditorConfig is awesome: http://EditorConfig.org | ||
|
||
# top-most EditorConfig file | ||
root = true | ||
|
||
[*] | ||
charset = utf-8 | ||
end_of_line = lf | ||
insert_final_newline = true | ||
trim_trailing_whitespace = true | ||
|
||
[{*.php,*.json,*.md,*.html,*.css,*.js,*.yml}] | ||
indent_style = space | ||
indent_size = 4 |
This file contains 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 |
---|---|---|
@@ -1,3 +1,5 @@ | ||
vendor | ||
composer.lock | ||
.phpunit.cache | ||
.phpunit.result.cache | ||
.php-cs-fixer.cache |
This file contains 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,25 @@ | ||
<?php | ||
|
||
declare(strict_types=1); | ||
|
||
$finder = (new PhpCsFixer\Finder()) | ||
->ignoreDotFiles(false) | ||
->ignoreVCSIgnored(true) | ||
->in(__DIR__) | ||
; | ||
|
||
return (new PhpCsFixer\Config()) | ||
->setRiskyAllowed(true) | ||
->setRules([ | ||
'@PHP74Migration' => true, | ||
'@PHP74Migration:risky' => true, | ||
'@PHPUnit100Migration:risky' => true, | ||
'@PhpCsFixer' => true, | ||
'@PhpCsFixer:risky' => true, | ||
'yoda_style' => true, | ||
'general_phpdoc_annotation_remove' => ['annotations' => ['expectedDeprecation']], // one should use PHPUnit built-in method instead | ||
'modernize_strpos' => true, // needs PHP 8+ or polyfill | ||
'no_useless_concat_operator' => false, // TODO switch back on when the `src/Console/Application.php` no longer needs the concat | ||
]) | ||
->setFinder($finder) | ||
; |
This file contains 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 |
---|---|---|
@@ -1,54 +1,58 @@ | ||
{ | ||
"name": "symftony/xpression", | ||
"authors": [ | ||
{ | ||
"name": "Anthony", | ||
"email": "[email protected]" | ||
"name": "symftony/xpression", | ||
"authors": [ | ||
{ | ||
"name": "Anthony", | ||
"email": "[email protected]" | ||
} | ||
], | ||
"type": "library", | ||
"description": "Xpression is a simple PHP implementation of Specification pattern", | ||
"keywords": [ | ||
"dsl", | ||
"doctrine", | ||
"orm", | ||
"mongodb", | ||
"collections", | ||
"specification", | ||
"expression", | ||
"parser", | ||
"lexer", | ||
"query", | ||
"builder", | ||
"query builder" | ||
], | ||
"homepage": "https://github.com/symftony/Xpression", | ||
"require": { | ||
"php": "^8.0", | ||
"doctrine/lexer": "^1.0" | ||
}, | ||
"require-dev": { | ||
"doctrine/collections": "^1.0", | ||
"doctrine/orm": "^2.4.0", | ||
"phpspec/prophecy": "^1.18", | ||
"phpunit/phpunit": "^9.6", | ||
"friendsofphp/php-cs-fixer": "^3.41", | ||
"phpstan/phpstan": "^1.10" | ||
}, | ||
"scripts": { | ||
"test": "vendor/bin/phpunit", | ||
"cs": "vendor/bin/php-cs-fixer fix", | ||
"stan": "vendor/bin/phpstan analyse" | ||
}, | ||
"suggest": { | ||
"doctrine/collections": "If you want filter an ArrayCollection", | ||
"doctrine/orm": "If you want filter an ORM query builder" | ||
}, | ||
"license": "MIT", | ||
"autoload": { | ||
"psr-4": { | ||
"Symftony\\Xpression\\": "src/" | ||
} | ||
}, | ||
"autoload-dev": { | ||
"psr-4": { | ||
"Tests\\Symftony\\Xpression\\": "tests/" | ||
} | ||
} | ||
], | ||
"type": "library", | ||
"description": "Xpression is a simple PHP implementation of Specification pattern", | ||
"keywords": [ | ||
"dsl", | ||
"doctrine", | ||
"orm", | ||
"mongodb", | ||
"collections", | ||
"specification", | ||
"expression", | ||
"parser", | ||
"lexer", | ||
"query", | ||
"builder", | ||
"query builder" | ||
], | ||
"homepage": "https://github.com/symftony/Xpression", | ||
"require": { | ||
"php": "^8.0", | ||
"doctrine/lexer": "^1.0" | ||
}, | ||
"require-dev": { | ||
"doctrine/collections": "^1.0", | ||
"doctrine/orm": "^2.4.0", | ||
"phpspec/prophecy": "^1.18", | ||
"phpunit/phpunit": "^9.6" | ||
}, | ||
"scripts": { | ||
"test": "vendor/bin/phpunit" | ||
}, | ||
"suggest": { | ||
"doctrine/collections": "If you want filter an ArrayCollection", | ||
"doctrine/orm": "If you want filter an ORM query builder" | ||
}, | ||
"license": "MIT", | ||
"autoload": { | ||
"psr-4": { | ||
"Symftony\\Xpression\\": "src/" | ||
} | ||
}, | ||
"autoload-dev": { | ||
"psr-4": { | ||
"Tests\\Symftony\\Xpression\\": "tests/" | ||
} | ||
} | ||
} |
This file contains 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,8 @@ | ||
parameters: | ||
level: 6 | ||
paths: | ||
- src | ||
ignoreErrors: | ||
- '/Method .*::(in|notIn|andX|nandX|orX|norX|xorX)\(\) has parameter .* with no value type specified in iterable type array\./' | ||
- '/Method Symftony\\Xpression\\Parser::getNextToken\(\) return type has no value type specified in iterable type array\./' | ||
- '/Method Symftony\\Xpression\\Lexer::get(Non)?CatchablePatterns\(\) return type has no value type specified in iterable type array\./' |
This file contains 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
This file contains 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
Oops, something went wrong.