Skip to content

Commit

Permalink
Merge pull request #7 from nextcloud/php-cs-fixer-3
Browse files Browse the repository at this point in the history
use php-cs-fixer ^3.2
  • Loading branch information
ChristophWurst committed Nov 10, 2021
2 parents 68370dd + 38f3845 commit 0c25047
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 10 deletions.
1 change: 1 addition & 0 deletions .gitignore
Expand Up @@ -5,3 +5,4 @@ composer.phar
/.idea

.php_cs.cache
.php-cs-fixer.cache
File renamed without changes.
4 changes: 2 additions & 2 deletions composer.json
Expand Up @@ -3,8 +3,8 @@
"description": "Nextcloud coding standards for the php cs fixer",
"type": "library",
"require": {
"php": "^7.2|^8.0",
"friendsofphp/php-cs-fixer": "^2.17"
"php": "^7.3|^8.0",
"friendsofphp/php-cs-fixer": "^3.2"
},
"license": "MIT",
"authors": [
Expand Down
12 changes: 4 additions & 8 deletions src/Config.php
Expand Up @@ -12,15 +12,12 @@ public function __construct($name = 'default') {
$this->setIndent("\t");
}

public function getRules() {
public function getRules() : array {
return [
'@PSR1' => true,
'@PSR2' => true,
'align_multiline_comment' => true,
'array_indentation' => true,
'array_syntax' => [
'syntax' => 'short',
],
'binary_operator_spaces' => [
'default' => 'single_space',
],
Expand All @@ -39,11 +36,10 @@ public function getRules() {
],
'indentation_type' => true,
'line_ending' => true,
'list_syntax' => [
'syntax' => 'short',
],
'lowercase_keywords' => true,
'method_argument_space' => [],
'method_argument_space' => [
'on_multiline' => 'ignore',
],
'no_closing_tag' => true,
'no_spaces_after_function_name' => true,
'no_spaces_inside_parenthesis' => true,
Expand Down

0 comments on commit 0c25047

Please sign in to comment.