Skip to content

Commit

Permalink
chore(commit): Update .editorconfig and psalm configuration
Browse files Browse the repository at this point in the history
- Update the order and values of properties in the .editorconfig file
- Change the indent size and end-of-line settings
- Update the psalm.xml.dist and psalm-     baseline.xml files
- Remove an unused interface method occurrence in Handler.php
- Fix UndefinedMagicMethod occurrences in ConfigCommandTest.php
- Adjust errorLevel and   suppress errors in various files
  • Loading branch information
[email protected] committed Oct 15, 2024
1 parent 2283681 commit 95a643d
Show file tree
Hide file tree
Showing 3 changed files with 58 additions and 52 deletions.
12 changes: 8 additions & 4 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -1,12 +1,16 @@
root = true

[*]
charset = utf-8
end_of_line = lf
indent_size = 4
indent_style = space
insert_final_newline = true
indent_size = 4
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = false

[*.{vue,js,scss}]
indent_size = 2
insert_final_newline = true

[*.md]
trim_trailing_whitespace = false
Expand Down
5 changes: 0 additions & 5 deletions psalm-baseline.xml
Original file line number Diff line number Diff line change
@@ -1,10 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
<files psalm-version="4.30.0@d0bc6e25d89f649e4f36a534f330f8bb4643dd69">
<file src="app/Exceptions/Handler.php">
<UndefinedInterfaceMethod occurrences="1">
<code>isProduction</code>
</UndefinedInterfaceMethod>
</file>
<file src="tests/Feature/ConfigCommandTest.php">
<UndefinedMagicMethod occurrences="2">
<code>andReturn</code>
Expand Down
93 changes: 50 additions & 43 deletions psalm.xml.dist
Original file line number Diff line number Diff line change
@@ -1,49 +1,56 @@
<?xml version="1.0" encoding="UTF-8"?>
<psalm
errorLevel="4"
findUnusedVariablesAndParams="true"
resolveFromConfigFile="true"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="https://getpsalm.org/schema/config"
xsi:schemaLocation="https://getpsalm.org/schema/config vendor/vimeo/psalm/config.xsd"
cacheDirectory="./build/psalm/"
errorBaseline="psalm-baseline.xml"
cacheDirectory="./build/psalm/"
errorBaseline="psalm-baseline.xml"
errorLevel="4"
findUnusedBaselineEntry="true"
findUnusedCode="false"
findUnusedVariablesAndParams="true"
resolveFromConfigFile="true"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="https://getpsalm.org/schema/config"
xsi:schemaLocation="https://getpsalm.org/schema/config vendor/vimeo/psalm/config.xsd"
>
<projectFiles>
<directory name="app"/>
<directory name="tests"/>
<ignoreFiles allowMissingFiles="true">
<directory name="vendor"/>
<file name="app/xxx.php"/>
</ignoreFiles>
</projectFiles>
<projectFiles>
<directory name="app"/>
<directory name="tests"/>
<ignoreFiles allowMissingFiles="true">
<directory name="vendor"/>
<file name="app/xxx.php"/>
</ignoreFiles>
</projectFiles>

<issueHandlers>
<PropertyNotSetInConstructor errorLevel="info"/>
<UnusedVariable>
<errorLevel type="suppress">
<file name="app/Commands/CommitCommand.php"/>
<file name="app/Generators/OpenAIGenerator.php"/>
</errorLevel>
</UnusedVariable>
<InternalMethod>
<errorLevel type="suppress">
<directory name="tests"/>
</errorLevel>
</InternalMethod>
<InvalidScope>
<errorLevel type="suppress">
<directory name="tests"/>
</errorLevel>
</InvalidScope>
<UndefinedFunction>
<errorLevel type="suppress">
<directory name="tests"/>
</errorLevel>
</UndefinedFunction>
</issueHandlers>
<issueHandlers>
<PropertyNotSetInConstructor errorLevel="info"/>
<UnusedVariable>
<errorLevel type="suppress">
<file name="app/Commands/CommitCommand.php"/>
<file name="app/Generators/OpenAIGenerator.php"/>
</errorLevel>
</UnusedVariable>
<InternalMethod>
<errorLevel type="suppress">
<directory name="tests"/>
</errorLevel>
</InternalMethod>
<InvalidScope>
<errorLevel type="suppress">
<directory name="tests"/>
</errorLevel>
</InvalidScope>
<UndefinedFunction>
<errorLevel type="suppress">
<directory name="tests"/>
</errorLevel>
</UndefinedFunction>
<UndefinedPropertyFetch>
<errorLevel type="suppress">
<directory name="tests"/>
</errorLevel>
</UndefinedPropertyFetch>
</issueHandlers>

<plugins>
<!--<pluginClass class="Psalm\PhpUnitPlugin\Plugin"/>-->
</plugins>
<plugins>
<!--<pluginClass class="Psalm\PhpUnitPlugin\Plugin"/>-->
</plugins>
</psalm>

0 comments on commit 95a643d

Please sign in to comment.