Skip to content

Commit 61c5bae

Browse files
authored
Merge branch 'develop' into 142-import-test-rule
2 parents 975977d + da46c5d commit 61c5bae

File tree

5 files changed

+17
-3
lines changed

5 files changed

+17
-3
lines changed

.gitignore

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,8 @@
11
/vendor/*
22
/bin/*
3+
4+
# IDE files
5+
.idea/
6+
.project/
7+
.settings/
8+
.vscode/

Magento2/Sniffs/Functions/DiscouragedFunctionSniff.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ class DiscouragedFunctionSniff extends ForbiddenFunctionsSniff
113113
'^readlink$' => null,
114114
'^register_shutdown_function$' => null,
115115
'^register_tick_function$' => null,
116-
'^rename$' => 'Magento\Framework\Filesystem\DriverInterface::raname()',
116+
'^rename$' => 'Magento\Framework\Filesystem\DriverInterface::rename()',
117117
'^rmdir$' => 'Magento\Framework\Filesystem\DriverInterface::deleteDirectory()',
118118
'^scandir$' => null,
119119
'^session_.*$' => null,

README.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,14 @@ Once installed, you can run `phpcs` from the command-line to analyse your code `
4242
```
4343
$ vendor/bin/phpcs --standard=Magento2 app/code/MyAwesomeExtension
4444
```
45+
46+
### Fixing issues automatically
47+
Also you can run `phpcbf` from the command-line to fix your code `MyAwesomeExtension` for warnings like
48+
"PHPCBF CAN FIX THE [0-9]+ MARKED SNIFF VIOLATIONS AUTOMATICALLY"
49+
```
50+
$ vendor/bin/phpcbf --standard=Magento2 app/code/MyAwesomeExtension
51+
```
52+
4553
## Where to contribute
4654
- Documentation of existing rules. See [ExtDN PHP CodeSniffer rules for Magento 2](https://github.com/extdn/extdn-phpcs) as a good example.
4755
- Bug fixes and improvements of existing rules.

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
"AFL-3.0"
77
],
88
"type": "phpcodesniffer-standard",
9-
"version": "4",
9+
"version": "5",
1010
"require": {
1111
"php": ">=5.6.0",
1212
"squizlabs/php_codesniffer": "^3.4",

composer.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)