-
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.
Merge pull request #5 from clearlyip/feature/v3
- Loading branch information
Showing
38 changed files
with
1,436 additions
and
296 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,2 @@ | ||
/tests export-ignore | ||
/workbench export-ignore |
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,4 +1,8 @@ | ||
/vendor/ | ||
vendor | ||
# Before you hate on me for this https://stackoverflow.com/a/21589454 | ||
composer.lock | ||
package-lock.json | ||
/node_modules/ | ||
node_modules | ||
output | ||
.env | ||
.phpunit.cache | ||
package-lock.json |
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,6 +1,17 @@ | ||
{ | ||
"trailingCommaPHP": true, | ||
"singleQuote": true, | ||
"useTabs": false, | ||
"braceStyle": "psr-2" | ||
"tabWidth": 4, | ||
"singleQuote": true, | ||
"useTabs": false, | ||
"plugins": ["@prettier/plugin-php"], | ||
"overrides": [ | ||
{ | ||
"files": ["*.php"], | ||
"options": { | ||
"parser": "php", | ||
"phpVersion": "8.2", | ||
"trailingCommaPHP": true, | ||
"braceStyle": "psr-2" | ||
} | ||
} | ||
] | ||
} |
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 @@ | ||
{ | ||
// Use IntelliSense to learn about possible attributes. | ||
// Hover to view descriptions of existing attributes. | ||
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 | ||
"version": "0.2.0", | ||
"configurations": [ | ||
{ | ||
"name": "Listen for XDebug", | ||
"type": "php", | ||
"request": "launch", | ||
"port": 9001 | ||
} | ||
] | ||
} |
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,12 +1,25 @@ | ||
{ | ||
// I recommend to disable VS Code's built-in PHP IntelliSense by setting php.suggest.basic to false to avoid duplicate suggestions. | ||
"php.suggest.basic": false, | ||
"editor.formatOnSave": true, | ||
"[php]": { | ||
"editor.defaultFormatter": "esbenp.prettier-vscode" | ||
}, | ||
"workbench.colorCustomizations": {}, | ||
"taskExplorer.pathToMake": "make", | ||
"coverage-gutters.showLineCoverage": true, | ||
"coverage-gutters.showRulerCoverage": true, | ||
// I recommend to disable VS Code's built-in PHP IntelliSense by setting php.suggest.basic to false to avoid duplicate suggestions. | ||
"php.suggest.basic": false, | ||
"editor.formatOnSave": true, | ||
"[php]": { | ||
"editor.defaultFormatter": "esbenp.prettier-vscode" | ||
}, | ||
"workbench.colorCustomizations": {}, | ||
"psalm.configPaths": ["psalm.xml"], | ||
"psalm.psalmScriptPath": "vendor/bin/psalm-language-server", | ||
"phpCodeSniffer.exec.linux": "vendor/bin/phpcs", | ||
"phpCodeSniffer.standard": "Custom", | ||
"phpCodeSniffer.standardCustom": "phpcs.xml", | ||
"psalm.psalmScriptArgs": [ | ||
"--on-change-debounce-ms=500", | ||
"--show-diagnostic-warnings=false" | ||
], | ||
"editor.rulers": [80], | ||
"intelephense.environment.phpVersion": "8.2.0", | ||
"coverage-gutters.showLineCoverage": true, | ||
"coverage-gutters.showRulerCoverage": true, | ||
"coverage-gutters.coverageBaseDir": "output/**", | ||
"coverage-gutters.remotePathResolve": ["./"], | ||
"prettier.documentSelectors": ["**/*.php", "**/*.blade.php"] | ||
} |
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
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,19 +1,6 @@ | ||
{ | ||
"name": "@clearlyip/laravel-flagsmith", | ||
"version": "1.0.0", | ||
"main": "index.js", | ||
"directories": { | ||
"test": "tests" | ||
}, | ||
"private": true, | ||
"repository": { | ||
"type": "git", | ||
"url": "ssh://[email protected]:clearlyip/laravel-flagsmith.git" | ||
}, | ||
"author": "", | ||
"license": "BSD 3-Clause", | ||
"dependencies": { | ||
"@prettier/plugin-php": "^0.14.3", | ||
"prettier": "^2.1.2" | ||
"devDependencies": { | ||
"@prettier/plugin-php": "^0.21.0", | ||
"prettier": "^3.1.0" | ||
} | ||
} |
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,53 @@ | ||
<?xml version="1.0"?> | ||
<ruleset name="Custom Standard" namespace="MyProject\CS\Standard"> | ||
<!-- https://github.com/squizlabs/PHP_CodeSniffer/wiki/Annotated-Ruleset --> | ||
<description>ClearlyIP coding standards</description> | ||
<file>./src</file> | ||
<exclude-pattern>*/data/*</exclude-pattern> | ||
<exclude-pattern>*/node_modules/*</exclude-pattern> | ||
<exclude-pattern>*/vendor/*</exclude-pattern> | ||
<exclude-pattern>*/tests/*</exclude-pattern> | ||
<arg value="sp"/> | ||
|
||
<rule ref="PSR12"/> | ||
|
||
<!-- This option is good for inspecting extended methods, however using ReflectionClass may cause phpcs crashes while editing (not possible to catch FatalError). --> | ||
<!-- <autoload>./vendor/autoload.php</autoload> --> | ||
<!-- https://github.com/gskema/phpcs-type-sniff --> | ||
<!-- | ||
<rule ref="./vendor/gskema/phpcs-type-sniff/src/Sniffs/CompositeCodeElementSniff.php"> | ||
<properties> | ||
<property name="useReflection" value="true"/> | ||
</properties> | ||
<exclude name="Gskema.Sniffs.CompositeCodeElement.FqcnMethodSniff"/> | ||
<exclude name="Gskema.Sniffs.CompositeCodeElement.FqcnConstSniff"/> | ||
</rule> | ||
--> | ||
|
||
<rule ref="Generic.Files.LineLength.TooLong"> | ||
<!-- This is enforced by prettier --> | ||
<exclude name="Generic.Files.LineLength.TooLong"/> | ||
</rule> | ||
|
||
<rule ref="Squiz.ControlStructures.ForEachLoopDeclaration"> | ||
<!-- This will break as a result of prettier so dont enforce it --> | ||
<exclude name="Squiz.ControlStructures.ForEachLoopDeclaration.SpacingBeforeAs" /> | ||
</rule> | ||
|
||
<rule ref="Squiz.ControlStructures.ControlSignature"> | ||
<!-- This will break as a result of prettier so dont enforce it --> | ||
<exclude name="Squiz.ControlStructures.ControlSignature.SpaceAfterCloseBrace" /> | ||
</rule> | ||
|
||
<rule ref="Squiz.Functions.MultiLineFunctionDeclaration"> | ||
<!-- This will break as a result of prettier so dont enforce it --> | ||
<exclude name="Squiz.Functions.MultiLineFunctionDeclaration.OneParamPerLine" /> | ||
<exclude name="Squiz.Functions.MultiLineFunctionDeclaration.UseOneParamPerLine" /> | ||
</rule> | ||
|
||
<rule ref="Generic.WhiteSpace.DisallowTabIndent"> | ||
<exclude name="Generic.WhiteSpace.DisallowTabIndent.TabsUsed" /> | ||
</rule> | ||
|
||
|
||
</ruleset> |
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,36 @@ | ||
<?xml version="1.0"?> | ||
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/10.4/phpunit.xsd" bootstrap="vendor/autoload.php" executionOrder="depends,defects" beStrictAboutOutputDuringTests="true" failOnRisky="true" failOnWarning="true" colors="true" cacheDirectory=".phpunit.cache" requireCoverageMetadata="false" beStrictAboutCoverageMetadata="false"> | ||
<testsuites> | ||
<testsuite name="default"> | ||
<directory>tests</directory> | ||
</testsuite> | ||
</testsuites> | ||
<coverage> | ||
<report> | ||
<clover outputFile="output/coverage/cov.xml"/> | ||
<html outputDirectory="output/coverage/html"/> | ||
<text outputFile="php://stdout" showUncoveredFiles="false"/> | ||
</report> | ||
</coverage> | ||
<logging> | ||
<testdoxHtml outputFile="output/logging/testsDox.html"/> | ||
<testdoxText outputFile="output/logging/testsDox.txt"/> | ||
</logging> | ||
<source> | ||
<include> | ||
<directory suffix=".php">src</directory> | ||
</include> | ||
</source> | ||
<php> | ||
<server name="APP_ENV" value="testing"/> | ||
<server name="BCRYPT_ROUNDS" value="4"/> | ||
<server name="CACHE_DRIVER" value="array"/> | ||
<server name="MAIL_MAILER" value="array"/> | ||
<server name="QUEUE_CONNECTION" value="sync"/> | ||
<server name="SESSION_DRIVER" value="array"/> | ||
<server name="TELESCOPE_ENABLED" value="false"/> | ||
<server name="DB_CONNECTION" value="testing"/> | ||
<server name="REDIS_CLIENT" value="mock"/> | ||
<server name="APP_KEY" value="base64:+E3QzOdQTPu20d4VY93Oh99eVFhZmbA8D+mpj+r7wJs=" /> | ||
</php> | ||
</phpunit> |
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,16 @@ | ||
<?xml version="1.0"?> | ||
<psalm | ||
errorLevel="4" | ||
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="src"/> | ||
<directory name="tests"/> | ||
<ignoreFiles> | ||
<directory name="vendor"/> | ||
</ignoreFiles> | ||
</projectFiles> | ||
</psalm> |
Oops, something went wrong.