composer.json 8.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210
  1. {
  2. "name": "friendsofphp/php-cs-fixer",
  3. "description": "A tool to automatically fix PHP code style",
  4. "license": "MIT",
  5. "type": "application",
  6. "keywords": [
  7. "fixer",
  8. "standards",
  9. "static analysis",
  10. "static code analysis"
  11. ],
  12. "authors": [
  13. {
  14. "name": "Fabien Potencier",
  15. "email": "fabien@symfony.com"
  16. },
  17. {
  18. "name": "Dariusz Rumiński",
  19. "email": "dariusz.ruminski@gmail.com"
  20. }
  21. ],
  22. "require": {
  23. "php": "^7.4 || ^8.0",
  24. "ext-filter": "*",
  25. "ext-hash": "*",
  26. "ext-json": "*",
  27. "ext-tokenizer": "*",
  28. "clue/ndjson-react": "^1.0",
  29. "composer/semver": "^3.4",
  30. "composer/xdebug-handler": "^3.0.3",
  31. "fidry/cpu-core-counter": "^1.2",
  32. "react/child-process": "^0.6.5",
  33. "react/event-loop": "^1.0",
  34. "react/promise": "^2.0 || ^3.0",
  35. "react/socket": "^1.0",
  36. "react/stream": "^1.0",
  37. "sebastian/diff": "^4.0 || ^5.1 || ^6.0 || ^7.0",
  38. "symfony/console": "^5.4 || ^6.4 || ^7.0",
  39. "symfony/event-dispatcher": "^5.4 || ^6.4 || ^7.0",
  40. "symfony/filesystem": "^5.4 || ^6.4 || ^7.0",
  41. "symfony/finder": "^5.4 || ^6.4 || ^7.0",
  42. "symfony/options-resolver": "^5.4 || ^6.4 || ^7.0",
  43. "symfony/polyfill-mbstring": "^1.31",
  44. "symfony/polyfill-php80": "^1.31",
  45. "symfony/polyfill-php81": "^1.31",
  46. "symfony/process": "^5.4 || ^6.4 || ^7.2",
  47. "symfony/stopwatch": "^5.4 || ^6.4 || ^7.0"
  48. },
  49. "require-dev": {
  50. "facile-it/paraunit": "^1.3.1 || ^2.6",
  51. "infection/infection": "^0.29.14",
  52. "justinrainbow/json-schema": "^5.3 || ^6.2",
  53. "keradus/cli-executor": "^2.1",
  54. "mikey179/vfsstream": "^1.6.12",
  55. "php-coveralls/php-coveralls": "^2.7",
  56. "php-cs-fixer/accessible-object": "^1.1",
  57. "php-cs-fixer/phpunit-constraint-isidenticalstring": "^1.6",
  58. "php-cs-fixer/phpunit-constraint-xmlmatchesxsd": "^1.6",
  59. "phpunit/phpunit": "^9.6.22 || ^10.5.45 || ^11.5.12",
  60. "symfony/var-dumper": "^5.4.48 || ^6.4.18 || ^7.2.3",
  61. "symfony/yaml": "^5.4.45 || ^6.4.18 || ^7.2.3"
  62. },
  63. "suggest": {
  64. "ext-dom": "For handling output formats in XML",
  65. "ext-mbstring": "For handling non-UTF8 characters."
  66. },
  67. "autoload": {
  68. "psr-4": {
  69. "PhpCsFixer\\": "src/"
  70. },
  71. "exclude-from-classmap": [
  72. "src/Fixer/Internal/*"
  73. ]
  74. },
  75. "autoload-dev": {
  76. "psr-4": {
  77. "PhpCsFixer\\PHPStan\\": "dev-tools/phpstan/src/",
  78. "PhpCsFixer\\Tests\\": "tests/"
  79. },
  80. "exclude-from-classmap": [
  81. "tests/Fixtures/"
  82. ]
  83. },
  84. "bin": [
  85. "php-cs-fixer"
  86. ],
  87. "config": {
  88. "allow-plugins": {
  89. "ergebnis/composer-normalize": true,
  90. "infection/extension-installer": false
  91. },
  92. "prefer-stable": true,
  93. "sort-packages": true
  94. },
  95. "scripts": {
  96. "post-autoload-dump": [
  97. "@install-tools"
  98. ],
  99. "auto-review": [
  100. "Composer\\Config::disableProcessTimeout",
  101. "paraunit run --testsuite auto-review"
  102. ],
  103. "cs:check": "@php php-cs-fixer check --verbose --diff",
  104. "cs:fix": "@php php-cs-fixer fix",
  105. "cs:fix:parallel": [
  106. "echo '⚠️ This script is deprecated! Utilise built-in parallelisation instead.';",
  107. "@cs:fix"
  108. ],
  109. "docs": "@php dev-tools/doc.php",
  110. "infection": "@test:mutation",
  111. "install-tools": "@composer --working-dir=dev-tools install",
  112. "mess-detector": "@php dev-tools/vendor/bin/phpmd . ansi dev-tools/mess-detector/phpmd.xml --exclude vendor/*,dev-tools/vendor/*,dev-tools/phpstan/*,tests/Fixtures/*",
  113. "normalize": [
  114. "@composer normalize --working-dir=dev-tools --dry-run ../composer.json",
  115. "@composer normalize --working-dir=dev-tools --dry-run composer.json"
  116. ],
  117. "normalize:fix": [
  118. "@composer normalize --working-dir=dev-tools ../composer.json",
  119. "@composer normalize --working-dir=dev-tools composer.json"
  120. ],
  121. "php-compatibility": "@php dev-tools/vendor/bin/phpcs -p --standard=dev-tools/php-compatibility/phpcs-php-compatibility.xml",
  122. "phpstan": "@php -d memory_limit=512M dev-tools/vendor/bin/phpstan analyse",
  123. "phpstan:baseline": "@php -d memory_limit=512M dev-tools/vendor/bin/phpstan analyse --generate-baseline=./dev-tools/phpstan/baseline.php",
  124. "qa": "@quality-assurance",
  125. "quality-assurance": [
  126. "Composer\\Config::disableProcessTimeout",
  127. "@install-tools --quiet",
  128. "@self-check",
  129. "@static-analysis",
  130. "@test"
  131. ],
  132. "require-checker": "@php dev-tools/vendor/bin/composer-require-checker check composer.json --config-file .composer-require-checker.json",
  133. "sa": "@static-analysis",
  134. "self-check": [
  135. "./dev-tools/check_file_permissions.sh",
  136. "./dev-tools/check_trailing_spaces.sh",
  137. "@composer dump-autoload --dry-run --optimize --strict-psr",
  138. "@normalize",
  139. "@unused-deps",
  140. "@require-checker",
  141. "@auto-review"
  142. ],
  143. "static-analysis": [
  144. "@cs:check",
  145. "@phpstan",
  146. "@mess-detector"
  147. ],
  148. "test": "@test:all",
  149. "test:all": [
  150. "@test:unit",
  151. "@test:integration"
  152. ],
  153. "test:coverage": [
  154. "Composer\\Config::disableProcessTimeout",
  155. "@composer show facile-it/paraunit ^2 && (paraunit coverage --testsuite unit --pass-through=--exclude-group=covers-nothing) || (paraunit coverage --testsuite unit --exclude-group covers-nothing)"
  156. ],
  157. "test:integration": [
  158. "Composer\\Config::disableProcessTimeout",
  159. "paraunit run --testsuite integration"
  160. ],
  161. "test:mutation": [
  162. "Composer\\Config::disableProcessTimeout",
  163. "infection --threads=max --only-covered --min-covered-msi=80"
  164. ],
  165. "test:short-open-tag": [
  166. "Composer\\Config::disableProcessTimeout",
  167. "@php -d short_open_tag=1 ./vendor/bin/phpunit --do-not-cache-result --testsuite short-open-tag"
  168. ],
  169. "test:smoke": [
  170. "Composer\\Config::disableProcessTimeout",
  171. "paraunit run --testsuite smoke"
  172. ],
  173. "test:unit": [
  174. "Composer\\Config::disableProcessTimeout",
  175. "paraunit run --testsuite unit"
  176. ],
  177. "unused-deps": "@php dev-tools/vendor/bin/composer-unused --excludePackage=composer/xdebug-handler"
  178. },
  179. "scripts-descriptions": {
  180. "auto-review": "Execute Auto-review",
  181. "cs:check": "Check coding standards",
  182. "cs:fix": "Fix coding standards",
  183. "cs:fix:parallel": "⚠️DEPRECATED! Use cs:fix with proper parallel config",
  184. "docs": "Regenerate docs",
  185. "infection": "Alias for 'test:mutation'",
  186. "install-tools": "Install DEV tools",
  187. "mess-detector": "Analyse code with Mess Detector",
  188. "normalize": "Check normalization for composer.json files",
  189. "normalize:fix": "Run normalization for composer.json files",
  190. "php-compatibility": "Check compatibility with all supported PHP versions",
  191. "phpstan": "Run PHPStan analysis",
  192. "phpstan:baseline": "Dump PHPStan baseline file - use only for updating, do not add new errors when possible",
  193. "post-autoload-dump": "Run additional tasks after installing/updating main dependencies",
  194. "qa": "Alias for 'quality-assurance'",
  195. "quality-assurance": "Run QA suite",
  196. "require-checker": "Verifies if codebase does not contain soft dependencies",
  197. "sa": "Alias for 'static-analysis'",
  198. "self-check": "Run set of self-checks ensuring repository's validity",
  199. "static-analysis": "Run static analysis",
  200. "test": "Alias for 'test:all'",
  201. "test:all": "Run Unit and Integration tests (but *NOT* Smoke tests)",
  202. "test:coverage": "Run tests that provide code coverage",
  203. "test:integration": "Run Integration tests",
  204. "test:mutation": "Run mutation tests",
  205. "test:short-open-tag": "Run tests with \"short_open_tag\" enabled",
  206. "test:smoke": "Run Smoke tests",
  207. "test:unit": "Run Unit tests",
  208. "unused-deps": "Verifies if app has dependencies that are not used"
  209. }
  210. }