composer.json 7.9 KB

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