Skip to content

Commit 295f2b9

Browse files
committed
Add formatter
1 parent af7dd08 commit 295f2b9

File tree

3 files changed

+86
-2
lines changed

3 files changed

+86
-2
lines changed

composer.json

+7-1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,11 @@
99
"email": "[email protected]"
1010
}
1111
],
12+
"scripts": {
13+
"test": "vendor/bin/phpunit",
14+
"lint": "vendor/bin/phpcs",
15+
"format": "vendor/bin/phpcbf"
16+
},
1217
"autoload": {
1318
"psr-4": {
1419
"Appwrite\\SDK\\": "src/SDK",
@@ -28,7 +33,8 @@
2833
},
2934
"require-dev": {
3035
"phpunit/phpunit": "^9.5.21",
31-
"brianium/paratest": "^6.4"
36+
"brianium/paratest": "^6.4",
37+
"squizlabs/php_codesniffer": "^3.6"
3238
},
3339
"minimum-stability": "dev",
3440
"prefer-stable": true

composer.lock

+57-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

phpcs.xml

+22
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
<?xml version="1.0"?>
2+
3+
<ruleset name="Appwrite Standard" namespace="Appwrite">
4+
<rule ref="PSR12"/>
5+
<file>./src</file>
6+
<file>./tests</file>
7+
<ini name="memory_limit" value="4096M"/>
8+
9+
<!-- Exclude SDKs and resources for performance reasons -->
10+
<exclude-pattern>./tests/sdks</exclude-pattern>
11+
<exclude-pattern>./tests/languages</exclude-pattern>
12+
<exclude-pattern>./tests/resources</exclude-pattern>
13+
14+
<!-- Ignore max line width -->
15+
<rule ref="Generic.Files.LineLength">
16+
<exclude-pattern>*</exclude-pattern>
17+
</rule>
18+
<!-- Allow Side Effects on root level of files -->
19+
<rule ref="PSR1.Files.SideEffects.FoundWithSymbols">
20+
<exclude-pattern>*</exclude-pattern>
21+
</rule>
22+
</ruleset>

0 commit comments

Comments
 (0)