Skip to content

Instantly share code, notes, and snippets.

@Shelob9 Shelob9/all-scripts.json
Last active Nov 29, 2018

Embed
What would you like to do?
{
"scripts" : {
"tests" : "composer fixes && composer sniffs && composer lints && phpunit --coverage-clover coverage/clover.xml",
"sniffs" : "phpcs --standard=PSR2 src/ && phpcs --standard=PSR2 tests/",
"fixes" : "php-cs-fixer fix src/ && php-cs-fixer fix tests/",
"lints" : "parallel-lint ./src --blame --exclude vendor && parallel-lint ./tests --blame --exclude vendor"
}
}
{
"name": "example/example",
"type": "wordpress-plugin",
"license": "GPL-2.0",
"minimum-stability": "dev",
"require": {
"php" : "^5.6"
},
"require-dev" : {
"phpunit/phpunit": "^6.1",
"php-coveralls/php-coveralls": "^2.0@dev",
"squizlabs/php_codesniffer": "3.*",
"friendsofphp/php-cs-fixer": "^2.9",
"jakub-onderka/php-parallel-lint": "dev-master",
"jakub-onderka/php-console-highlighter": "dev-master",
},
"autoload": {
"psr-4": {
"example\\example\\": "src"
}
},
"autoload-dev": {
"psr-4": {
"example\\example\\Tests\\": "tests/"
}
},
"scripts" : {
"tests" : "composer fixes && composer sniffs && composer lints && phpunit --coverage-clover coverage/clover.xml",
"tests-now" : "phpunit --group=now",
"sniffs" : "phpcs --standard=PSR2 src/ && phpcs --standard=PSR2 tests/",
"fixes" : "php-cs-fixer fix src/ && php-cs-fixer fix tests/",
"lints" : "parallel-lint ./src --blame --exclude vendor && parallel-lint ./tests --blame --exclude vendor"
},
"config": {
"optimize-autoloader": true,
"platform": {
"php" : "^5.6"
}
}
}
compsoer require friendsofphp/php-cs-fixer --dev
composer require squizlabs/php_codesniffer --dev
composer require jakub-onderka/php-parallel-lint
{
"scripts" : {
"sniffs" : "phpcs --standard=PSR2 src/ && phpcs --standard=PSR2 tests/",
"fixes" : "php-cs-fixer fix src/ && php-cs-fixer fix tests/",
"lints" : "parallel-lint ./src --blame --exclude vendor && parallel-lint ./tests --blame --exclude vendor"
}
}
{
"scripts" : {
"sniffs" : "phpcs --standard=PSR2 src/ && phpcs --standard=PSR2 tests/",
"fixes" : "php-cs-fixer fix src/ && php-cs-fixer fix tests/"
}
}
{
"scripts" : {
"sniffs" : "phpcs --standard=PSR2 src/ && phpcs --standard=PSR2 tests/"
}
}
@ninovandenheuvel

This comment has been minimized.

Copy link

ninovandenheuvel commented Jan 19, 2018

Really curious on this. Will see if I can add it to my projects.
It does seems 'install-code-fixer.sh' has a typo in composer command.

@virtualLast

This comment has been minimized.

Copy link

virtualLast commented Nov 29, 2018

"lints" : "parallel-lint ./src --blame --exclude vendor && parallel-lint ./Tests --blame --exclude vendor && parallel-lint ./public --blame --exclude vendor && parallel-lint ./admin --blame --exclude vendor && parallel-lint ./includes --blame --exclude vendor"

I have adjusted the lints portion for my project, but when I run composer lints it says no file found to check and errors with code 225, any idea's here?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.