wp-studio 1.7.8-beta2 → 1.7.8-beta3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (219) hide show
  1. package/README.md +33 -0
  2. package/assets/demo.gif +0 -0
  3. package/dist/cli/{_events-BRGCap7g.mjs → _events-C60cNJ1W.mjs} +1 -1
  4. package/dist/cli/{index-9Oz-0bqF.mjs → index-D9syEMMz.mjs} +4 -4
  5. package/dist/cli/{index-CT4S2538.mjs → index-Ru6CUP6w.mjs} +24 -12
  6. package/dist/cli/{login-D4E3GoXe.mjs → login-C3QlGVbr.mjs} +1 -1
  7. package/dist/cli/{logout-DE-RoshK.mjs → logout-B63eZwJZ.mjs} +1 -1
  8. package/dist/cli/main.mjs +2 -1
  9. package/dist/cli/{resume-DLoXmzNG.mjs → resume-DQT_MK6A.mjs} +1 -1
  10. package/dist/cli/{set-B0L-QiXT.mjs → set-C805heQS.mjs} +1 -1
  11. package/dist/cli/{set-B8YYUENH.mjs → set-CjTbueyB.mjs} +1 -1
  12. package/dist/cli/{status-DEOAA0yx.mjs → status-SnKm1rRP.mjs} +1 -1
  13. package/dist/cli/{wp-CobSX6C6.mjs → wp-D0HZdudM.mjs} +1 -1
  14. package/dist/cli/wp-files/sqlite-command/composer.json +4 -3
  15. package/dist/cli/wp-files/sqlite-command/composer.lock +132 -80
  16. package/dist/cli/wp-files/sqlite-command/vendor/autoload.php +1 -1
  17. package/dist/cli/wp-files/sqlite-command/vendor/composer/autoload_classmap.php +58 -70
  18. package/dist/cli/wp-files/sqlite-command/vendor/composer/autoload_namespaces.php +1 -0
  19. package/dist/cli/wp-files/sqlite-command/vendor/composer/autoload_psr4.php +1 -1
  20. package/dist/cli/wp-files/sqlite-command/vendor/composer/autoload_real.php +5 -5
  21. package/dist/cli/wp-files/sqlite-command/vendor/composer/autoload_static.php +78 -80
  22. package/dist/cli/wp-files/sqlite-command/vendor/composer/installed.json +104 -49
  23. package/dist/cli/wp-files/sqlite-command/vendor/composer/installed.php +29 -16
  24. package/dist/cli/wp-files/sqlite-command/vendor/symfony/finder/CHANGELOG.md +103 -0
  25. package/dist/cli/wp-files/sqlite-command/vendor/symfony/finder/Comparator/Comparator.php +62 -0
  26. package/dist/cli/wp-files/sqlite-command/vendor/symfony/finder/Comparator/DateComparator.php +50 -0
  27. package/dist/cli/wp-files/sqlite-command/vendor/symfony/finder/Comparator/NumberComparator.php +78 -0
  28. package/dist/cli/wp-files/sqlite-command/vendor/symfony/finder/Exception/AccessDeniedException.php +19 -0
  29. package/dist/cli/wp-files/sqlite-command/vendor/symfony/finder/Exception/DirectoryNotFoundException.php +19 -0
  30. package/dist/cli/wp-files/sqlite-command/vendor/symfony/finder/Finder.php +851 -0
  31. package/dist/cli/wp-files/sqlite-command/vendor/symfony/finder/Gitignore.php +91 -0
  32. package/dist/cli/wp-files/sqlite-command/vendor/symfony/finder/Glob.php +116 -0
  33. package/dist/cli/wp-files/sqlite-command/vendor/symfony/finder/Iterator/CustomFilterIterator.php +61 -0
  34. package/dist/cli/wp-files/sqlite-command/vendor/symfony/finder/Iterator/DateRangeFilterIterator.php +58 -0
  35. package/dist/cli/wp-files/sqlite-command/vendor/symfony/finder/Iterator/DepthRangeFilterIterator.php +48 -0
  36. package/dist/cli/wp-files/sqlite-command/vendor/symfony/finder/Iterator/ExcludeDirectoryFilterIterator.php +110 -0
  37. package/dist/cli/wp-files/sqlite-command/vendor/symfony/finder/Iterator/FileTypeFilterIterator.php +51 -0
  38. package/dist/cli/wp-files/sqlite-command/vendor/symfony/finder/Iterator/FilecontentFilterIterator.php +58 -0
  39. package/dist/cli/wp-files/sqlite-command/vendor/symfony/finder/Iterator/FilenameFilterIterator.php +45 -0
  40. package/dist/cli/wp-files/sqlite-command/vendor/symfony/finder/Iterator/LazyIterator.php +32 -0
  41. package/dist/cli/wp-files/sqlite-command/vendor/symfony/finder/Iterator/MultiplePcreFilterIterator.php +107 -0
  42. package/dist/cli/wp-files/sqlite-command/vendor/symfony/finder/Iterator/PathFilterIterator.php +56 -0
  43. package/dist/cli/wp-files/sqlite-command/vendor/symfony/finder/Iterator/RecursiveDirectoryIterator.php +134 -0
  44. package/dist/cli/wp-files/sqlite-command/vendor/symfony/finder/Iterator/SizeRangeFilterIterator.php +57 -0
  45. package/dist/cli/wp-files/sqlite-command/vendor/symfony/finder/Iterator/SortableIterator.php +115 -0
  46. package/dist/cli/wp-files/sqlite-command/vendor/symfony/finder/Iterator/VcsIgnoredFilterIterator.php +173 -0
  47. package/dist/cli/wp-files/sqlite-command/vendor/symfony/finder/LICENSE +19 -0
  48. package/dist/cli/wp-files/sqlite-command/vendor/symfony/finder/README.md +14 -0
  49. package/dist/cli/wp-files/sqlite-command/vendor/symfony/finder/SplFileInfo.php +80 -0
  50. package/dist/cli/wp-files/sqlite-command/vendor/symfony/finder/composer.json +31 -0
  51. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/mustache/.gitattributes +8 -0
  52. package/dist/cli/wp-files/sqlite-command/vendor/{mustache → wp-cli}/mustache/LICENSE +1 -1
  53. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/mustache/README.md +76 -0
  54. package/dist/cli/wp-files/sqlite-command/vendor/{mustache → wp-cli}/mustache/composer.json +6 -16
  55. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/mustache/src/Mustache/Autoloader.php +88 -0
  56. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Cache/AbstractCache.php +7 -15
  57. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Cache/FilesystemCache.php +15 -20
  58. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Cache/NoopCache.php +4 -8
  59. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Cache.php +7 -10
  60. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Compiler.php +87 -144
  61. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Context.php +19 -23
  62. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Engine.php +134 -251
  63. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Exception/InvalidArgumentException.php +2 -6
  64. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Exception/LogicException.php +2 -6
  65. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Exception/RuntimeException.php +2 -6
  66. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Exception/SyntaxException.php +8 -7
  67. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Exception/UnknownFilterException.php +7 -7
  68. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Exception/UnknownHelperException.php +7 -7
  69. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Exception/UnknownTemplateException.php +7 -7
  70. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Exception.php +5 -4
  71. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/HelperCollection.php +17 -22
  72. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/LambdaHelper.php +8 -28
  73. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Loader/ArrayLoader.php +9 -12
  74. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Loader/CascadingLoader.php +15 -18
  75. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Loader/FilesystemLoader.php +18 -24
  76. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Loader/InlineLoader.php +13 -19
  77. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Loader/MutableLoader.php +7 -4
  78. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Loader/ProductionFilesystemLoader.php +16 -23
  79. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Loader/StringLoader.php +4 -8
  80. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Loader.php +7 -8
  81. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Logger/AbstractLogger.php +26 -22
  82. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Logger/StreamLogger.php +20 -25
  83. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Logger.php +37 -13
  84. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Parser.php +93 -100
  85. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Source/FilesystemSource.php +7 -11
  86. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Source.php +5 -4
  87. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Template.php +32 -39
  88. package/dist/cli/wp-files/sqlite-command/vendor/{mustache/mustache/src → wp-cli/mustache/src/Mustache}/Tokenizer.php +29 -33
  89. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/.actrc +3 -0
  90. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/.gitattributes +6 -0
  91. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/.mailmap +234 -0
  92. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/README.md +4 -4
  93. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/VERSION +1 -1
  94. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/bundle/rmccue/requests/CHANGELOG.md +0 -65
  95. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/bundle/rmccue/requests/README.md +1 -2
  96. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/bundle/rmccue/requests/certificates/cacert.pem +372 -315
  97. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/bundle/rmccue/requests/certificates/cacert.pem.sha256 +1 -1
  98. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/bundle/rmccue/requests/composer.json +5 -7
  99. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/bundle/rmccue/requests/src/Iri.php +18 -20
  100. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/bundle/rmccue/requests/src/Requests.php +1 -1
  101. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/bundle/rmccue/requests/src/Response/Headers.php +1 -1
  102. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/bundle/rmccue/requests/src/Transport/Curl.php +1 -5
  103. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/bundle/rmccue/requests/src/Transport/Fsockopen.php +0 -2
  104. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/bundle/rmccue/requests/src/Utility/CaseInsensitiveDictionary.php +0 -12
  105. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/bundle/rmccue/requests/src/Utility/FilteredIterator.php +2 -2
  106. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/composer.json +13 -30
  107. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/dependencies.yml +6 -0
  108. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/manifest.json +1 -1
  109. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Autoloader.php +2 -4
  110. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Bootstrap/AutoloaderStep.php +1 -10
  111. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Bootstrap/CheckRoot.php +2 -20
  112. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Bootstrap/DefineProtectedCommands.php +3 -3
  113. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Bootstrap/IncludeFrameworkAutoloader.php +4 -3
  114. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Bootstrap/IncludeRequestsAutoloader.php +3 -4
  115. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Bootstrap/InitializeContexts.php +0 -3
  116. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Bootstrap/InitializeLogger.php +1 -1
  117. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Bootstrap/LaunchRunner.php +3 -6
  118. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Bootstrap/{RegisterShutdownHandler.php → LoadDispatcher.php} +4 -6
  119. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Bootstrap/LoadRequiredCommand.php +5 -9
  120. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Bootstrap/LoadUtilityFunctions.php +0 -1
  121. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Completions.php +6 -149
  122. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Configurator.php +49 -202
  123. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Context/Admin.php +21 -113
  124. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Context/Auto.php +1 -1
  125. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Context/Cli.php +1 -0
  126. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Context/Frontend.php +1 -0
  127. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Dispatcher/CommandFactory.php +26 -63
  128. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Dispatcher/CompositeCommand.php +9 -19
  129. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Dispatcher/Subcommand.php +19 -284
  130. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/DocParser.php +5 -17
  131. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Exception/NonExistentKeyException.php +3 -6
  132. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Extractor.php +54 -30
  133. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Fetchers/Base.php +3 -7
  134. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Fetchers/Comment.php +2 -4
  135. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Fetchers/Post.php +3 -8
  136. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Fetchers/Signup.php +1 -3
  137. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Fetchers/Site.php +4 -12
  138. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Fetchers/User.php +1 -3
  139. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/FileCache.php +33 -135
  140. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Formatter.php +57 -221
  141. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Inflector.php +4 -4
  142. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Iterators/CSV.php +1 -6
  143. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Iterators/Query.php +1 -3
  144. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Iterators/Table.php +1 -7
  145. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Iterators/Transform.php +0 -2
  146. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Loggers/Base.php +0 -15
  147. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Loggers/Quiet.php +3 -2
  148. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Loggers/Regular.php +3 -4
  149. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/NoOp.php +0 -4
  150. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Process.php +7 -40
  151. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/RequestsLibrary.php +1 -4
  152. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Runner.php +234 -795
  153. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/SynopsisParser.php +26 -116
  154. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/SynopsisValidator.php +1 -1
  155. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Traverser/RecursiveDataStructureTraverser.php +26 -69
  156. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/UpgraderSkin.php +1 -1
  157. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/WpHttpCacheManager.php +5 -67
  158. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/WpOrgApi.php +3 -3
  159. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/boot-fs.php +2 -2
  160. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/bootstrap.php +2 -5
  161. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/class-wp-cli.php +62 -311
  162. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/commands/src/CLI_Alias_Command.php +60 -292
  163. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/commands/src/CLI_Cache_Command.php +1 -1
  164. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/commands/src/CLI_Command.php +31 -191
  165. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/commands/src/Help_Command.php +35 -177
  166. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/config-spec.php +4 -28
  167. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/utils-wp.php +47 -81
  168. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/utils.php +200 -512
  169. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/wp-cli.php +2 -2
  170. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/wp-settings-cli.php +465 -0
  171. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/templates/man-params.mustache +4 -0
  172. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/templates/man.mustache +0 -8
  173. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/ArgValidationTest.php +74 -0
  174. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/CommandFactoryTest.php +420 -0
  175. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/ConfiguratorTest.php +87 -0
  176. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/DocParserTest.php +213 -0
  177. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/ExtractorTest.php +293 -0
  178. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/FileCacheTest.php +207 -0
  179. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/HelpTest.php +119 -0
  180. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/InflectorTest.php +37 -0
  181. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/LoggingTest.php +124 -0
  182. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/ProcessTest.php +30 -0
  183. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/SynopsisParserTest.php +194 -0
  184. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/UtilsTest.php +1092 -0
  185. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/WPCLITest.php +16 -0
  186. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/WP_CLI/Iterators/CSVTest.php +109 -0
  187. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/WP_CLI/Traversers/RecursiveDataStructureTraverserTest.php +151 -0
  188. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/WP_CLI/WpOrgApiTest.php +166 -0
  189. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/WpVersionCompareTest.php +78 -0
  190. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/bootstrap.php +17 -0
  191. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/data/commandfactory-doc_comment-class-win.php +70 -0
  192. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/data/commandfactory-doc_comment-class.php +70 -0
  193. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/data/commandfactory-doc_comment-function-win.php +19 -0
  194. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/data/commandfactory-doc_comment-function.php +19 -0
  195. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/data/expand_globs/bar.ab2 +0 -0
  196. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/data/expand_globs/baz.ab1 +0 -0
  197. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/data/expand_globs/baz.ac1 +0 -0
  198. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/data/expand_globs/baz.efg2 +0 -0
  199. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/data/expand_globs/foo.ab1 +0 -0
  200. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/data/expand_globs/foo.ab2 +0 -0
  201. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/data/expand_globs/foo.efg1 +0 -0
  202. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/data/expand_globs/foo.efg2 +0 -0
  203. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/tests/mock-requests-transport.php +34 -0
  204. package/dist/cli/wp-files/sqlite-command/version +1 -1
  205. package/package.json +4 -3
  206. package/dist/cli/wp-files/sqlite-command/vendor/mustache/mustache/.php-cs-fixer.php +0 -20
  207. package/dist/cli/wp-files/sqlite-command/vendor/mustache/mustache/README.md +0 -94
  208. package/dist/cli/wp-files/sqlite-command/vendor/mustache/mustache/src/RenderedString.php +0 -51
  209. package/dist/cli/wp-files/sqlite-command/vendor/mustache/mustache/src/compat.php +0 -282
  210. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/.typos.toml +0 -14
  211. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/AGENTS.md +0 -121
  212. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/bundle/rmccue/requests/scripts/proxy/proxy.py +0 -5
  213. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/bundle/rmccue/requests/scripts/proxy/start.sh +0 -19
  214. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/bundle/rmccue/requests/scripts/proxy/stop.sh +0 -10
  215. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/Path.php +0 -260
  216. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/php/WP_CLI/ShutdownHandler.php +0 -329
  217. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/schemas/wp-cli-config.json +0 -218
  218. package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/schemas/wp-cli.example.yml +0 -55
  219. /package/dist/cli/wp-files/sqlite-command/vendor/wp-cli/wp-cli/{codecov.yml → tests/data/expand_globs/bar.ab1} +0 -0
@@ -10,51 +10,37 @@ use WP_CLI;
10
10
 
11
11
  /**
12
12
  * Output one or more items in a given format (e.g. table, JSON).
13
- *
14
- * @property-read string $format
15
- * @property-read string[] $fields
16
- * @property-read string|null $field
17
- * @property-read array<string, int> $alignments
18
13
  */
19
14
  class Formatter {
20
15
 
21
- /**
22
- * Maximum width for a table cell value.
23
- * Values longer than this will be truncated to improve performance.
24
- *
25
- * @var int
26
- */
27
- const MAX_CELL_WIDTH = 2048;
28
-
29
16
  /**
30
17
  * How the items should be output.
31
18
  *
32
- * @var array{format: string, fields: string[], field: string|null, alignments: array<string, int>}
19
+ * @var array
33
20
  */
34
21
  private $args;
35
22
 
36
23
  /**
37
24
  * Standard prefix for object fields.
38
25
  *
39
- * @var string|false
26
+ * @var string
40
27
  */
41
28
  private $prefix;
42
29
 
43
30
  /**
44
31
  * @param array $assoc_args Output format arguments.
45
32
  * @param array $fields Fields to display of each item.
46
- * @param string|false $prefix Check if fields have a standard prefix.
33
+ * @param string|bool $prefix Check if fields have a standard prefix.
47
34
  * False indicates empty prefix.
48
35
  */
49
36
  public function __construct( &$assoc_args, $fields = null, $prefix = false ) {
50
37
  $format_args = [
51
- 'format' => 'table',
52
- 'fields' => $fields,
53
- 'field' => null,
54
- 'alignments' => [],
38
+ 'format' => 'table',
39
+ 'fields' => $fields,
40
+ 'field' => null,
55
41
  ];
56
42
 
57
- foreach ( array_keys( $format_args ) as $key ) {
43
+ foreach ( [ 'format', 'fields', 'field' ] as $key ) {
58
44
  if ( isset( $assoc_args[ $key ] ) ) {
59
45
  $format_args[ $key ] = $assoc_args[ $key ];
60
46
  unset( $assoc_args[ $key ] );
@@ -65,10 +51,7 @@ class Formatter {
65
51
  $format_args['fields'] = explode( ',', $format_args['fields'] );
66
52
  }
67
53
 
68
- /** @var callable(string): string $trim */
69
- $trim = 'trim';
70
- // @phpstan-ignore argument.type
71
- $format_args['fields'] = array_map( $trim, $format_args['fields'] );
54
+ $format_args['fields'] = array_map( 'trim', $format_args['fields'] );
72
55
 
73
56
  $this->args = $format_args;
74
57
  $this->prefix = $prefix;
@@ -87,27 +70,29 @@ class Formatter {
87
70
  /**
88
71
  * Display multiple items according to the output arguments.
89
72
  *
90
- * @param iterable $items The items to display.
91
- * @param bool|array $ascii_pre_colorized Optional. A boolean or an array of booleans to pass to `format()` if items in the table are pre-colorized. Default false.
73
+ * @param array|Iterator $items The items to display.
74
+ * @param bool|array $ascii_pre_colorized Optional. A boolean or an array of booleans to pass to `format()` if items in the table are pre-colorized. Default false.
92
75
  */
93
76
  public function display_items( $items, $ascii_pre_colorized = false ) {
94
77
  if ( $this->args['field'] ) {
95
78
  $this->show_single_field( $items, $this->args['field'] );
96
79
  } else {
97
- // Convert iterator to array early to avoid consumption issues and enable validation
98
- if ( $items instanceof Iterator ) {
99
- $items = iterator_to_array( $items );
100
- }
101
-
102
- if ( in_array( $this->args['format'], [ 'csv', 'json', 'table', 'yaml' ], true ) ) {
103
- // Validate fields exist in at least one item
104
- if ( ! empty( $this->args['fields'] ) ) {
105
- $this->validate_fields( $items );
80
+ if ( in_array( $this->args['format'], [ 'csv', 'json', 'table' ], true ) ) {
81
+ $item = is_array( $items ) && ! empty( $items ) ? array_shift( $items ) : false;
82
+ if ( $item && ! empty( $this->args['fields'] ) ) {
83
+ foreach ( $this->args['fields'] as &$field ) {
84
+ $field = $this->find_item_key( $item, $field );
85
+ }
86
+ array_unshift( $items, $item );
106
87
  }
107
88
  }
108
89
 
109
90
  if ( in_array( $this->args['format'], [ 'table', 'csv' ], true ) ) {
110
- $items = array_map( [ $this, 'transform_item_values_to_json' ], (array) $items );
91
+ if ( $items instanceof Iterator ) {
92
+ $items = Utils\iterator_map( $items, [ $this, 'transform_item_values_to_json' ] );
93
+ } else {
94
+ $items = array_map( [ $this, 'transform_item_values_to_json' ], $items );
95
+ }
111
96
  }
112
97
 
113
98
  $this->format( $items, $ascii_pre_colorized );
@@ -122,14 +107,9 @@ class Formatter {
122
107
  */
123
108
  public function display_item( $item, $ascii_pre_colorized = false ) {
124
109
  if ( isset( $this->args['field'] ) ) {
125
- $item = (object) $item;
126
- $key = $this->find_item_key( $item, $this->args['field'], true );
127
- if ( null === $key ) {
128
- WP_CLI::warning( "Field not found in item: {$this->args['field']}." );
129
- $value = null;
130
- } else {
131
- $value = $item->$key;
132
- }
110
+ $item = (object) $item;
111
+ $key = $this->find_item_key( $item, $this->args['field'] );
112
+ $value = $item->$key;
133
113
  if ( in_array( $this->args['format'], [ 'table', 'csv' ], true ) && ( is_object( $value ) || is_array( $value ) ) ) {
134
114
  $value = json_encode( $value );
135
115
  }
@@ -140,42 +120,17 @@ class Formatter {
140
120
  ]
141
121
  );
142
122
  } else {
143
- /**
144
- * @var array $item
145
- */
146
123
  $this->show_multiple_fields( $item, $this->args['format'], $ascii_pre_colorized );
147
124
  }
148
125
  }
149
126
 
150
- /**
151
- * Truncate cell values in items for table/CSV output.
152
- *
153
- * @param iterable $items Items to process.
154
- * @param array $fields Fields to truncate.
155
- * @return array Processed items with truncated values.
156
- */
157
- private function truncate_items( $items, $fields ) {
158
- $truncated = [];
159
- foreach ( $items as $item ) {
160
- $row = Utils\pick_fields( $item, $fields );
161
- // Truncate each field value
162
- foreach ( $row as $key => $value ) {
163
- if ( is_string( $value ) && strlen( $value ) > self::MAX_CELL_WIDTH ) {
164
- $row[ $key ] = substr( $value, 0, self::MAX_CELL_WIDTH ) . '...';
165
- }
166
- }
167
- $truncated[] = $row;
168
- }
169
- return $truncated;
170
- }
171
-
172
127
  /**
173
128
  * Format items according to arguments.
174
129
  *
175
- * @param iterable $items Items.
130
+ * @param array $items
176
131
  * @param bool|array $ascii_pre_colorized Optional. A boolean or an array of booleans to pass to `show_table()` if items in the table are pre-colorized. Default false.
177
132
  */
178
- private function format( $items, $ascii_pre_colorized = false ): void {
133
+ private function format( $items, $ascii_pre_colorized = false ) {
179
134
  $fields = $this->args['fields'];
180
135
 
181
136
  switch ( $this->args['format'] ) {
@@ -190,25 +145,14 @@ class Formatter {
190
145
  if ( ! is_array( $items ) ) {
191
146
  $items = iterator_to_array( $items );
192
147
  }
193
- /** @var array<string> $items */
194
148
  echo implode( ' ', $items );
195
149
  break;
196
150
 
197
151
  case 'table':
198
- // Truncate large values before table formatting for performance
199
- if ( ! is_array( $items ) ) {
200
- $items = iterator_to_array( $items );
201
- }
202
- $items = $this->truncate_items( $items, $fields );
203
- $this->show_table( $items, $fields, $ascii_pre_colorized );
152
+ self::show_table( $items, $fields, $ascii_pre_colorized );
204
153
  break;
205
154
 
206
155
  case 'csv':
207
- // Truncate large values before CSV output for performance
208
- if ( ! is_array( $items ) ) {
209
- $items = iterator_to_array( $items );
210
- }
211
- $items = $this->truncate_items( $items, $fields );
212
156
  Utils\write_csv( STDOUT, $items, $fields );
213
157
  break;
214
158
 
@@ -239,35 +183,25 @@ class Formatter {
239
183
  /**
240
184
  * Show a single field from a list of items.
241
185
  *
242
- * @param iterable $items Array of objects to show fields from
243
- * @param string $field The field to show
186
+ * @param array $items Array of objects to show fields from
187
+ * @param string $field The field to show
244
188
  */
245
- private function show_single_field( $items, $field ): void {
246
- $key = null;
247
- $values = [];
248
- $field_found = false;
249
- $item_count = 0;
189
+ private function show_single_field( $items, $field ) {
190
+ $key = null;
191
+ $values = [];
250
192
 
251
193
  foreach ( $items as $item ) {
252
- ++$item_count;
253
194
  $item = (object) $item;
254
195
 
255
- // Resolve the key on first item that has the field
256
- if ( ! $field_found && null === $key ) {
257
- $key = $this->find_item_key( $item, $field, true );
258
- if ( null !== $key ) {
259
- $field_found = true;
260
- }
196
+ if ( null === $key ) {
197
+ $key = $this->find_item_key( $item, $field );
261
198
  }
262
199
 
263
- // Get value if key exists
264
- $value = ( null !== $key && isset( $item->$key ) ) ? $item->$key : null;
265
-
266
200
  if ( 'json' === $this->args['format'] ) {
267
- $values[] = $value;
201
+ $values[] = $item->$key;
268
202
  } else {
269
203
  WP_CLI::print_value(
270
- $value,
204
+ $item->$key,
271
205
  [
272
206
  'format' => $this->args['format'],
273
207
  ]
@@ -275,91 +209,28 @@ class Formatter {
275
209
  }
276
210
  }
277
211
 
278
- if ( ! $field_found && $item_count > 0 ) {
279
- WP_CLI::warning( "Field not found in any item: $field." );
280
- }
281
-
282
212
  if ( 'json' === $this->args['format'] ) {
283
213
  echo json_encode( $values );
284
214
  }
285
215
  }
286
216
 
287
- /**
288
- * Validate that requested fields exist in at least one item.
289
- * Warns if a field doesn't exist in any item.
290
- * Also resolves field names to their actual keys (including prefixes).
291
- *
292
- * @param iterable $items Items to validate
293
- */
294
- private function validate_fields( $items ): void {
295
- // Track which fields have been found and their resolved keys
296
- $fields_to_find = array_flip( $this->args['fields'] );
297
- $resolved_fields = [];
298
- $fields_count = count( $fields_to_find );
299
- $found_count = 0;
300
- $item_count = 0;
301
-
302
- // Iterate through items once and check all fields
303
- foreach ( $items as $item ) {
304
- ++$item_count;
305
- // Check each field that hasn't been found yet
306
- foreach ( $fields_to_find as $field => $_ ) {
307
- $key = $this->find_item_key( $item, $field, true );
308
- if ( null !== $key ) {
309
- // Store the resolved field name
310
- $resolved_fields[ $field ] = $key;
311
- // Mark this field as found
312
- unset( $fields_to_find[ $field ] );
313
- ++$found_count;
314
- // If all fields found, we can stop early
315
- if ( $found_count === $fields_count ) {
316
- break 2;
317
- }
318
- }
319
- }
320
- }
321
-
322
- // Update the fields array with resolved field names
323
- foreach ( $this->args['fields'] as &$field ) {
324
- if ( isset( $resolved_fields[ $field ] ) ) {
325
- $field = $resolved_fields[ $field ];
326
- }
327
- }
328
- unset( $field ); // Break the reference to avoid issues with subsequent foreach loops
329
-
330
- // Only warn about missing fields if there were items to check
331
- if ( $item_count > 0 ) {
332
- // Warn about any fields that weren't found in any item
333
- foreach ( $fields_to_find as $missing_field => $_ ) {
334
- WP_CLI::warning( "Field not found in any item: $missing_field." );
335
- }
336
- }
337
- }
338
-
339
217
  /**
340
218
  * Find an object's key.
341
219
  * If $prefix is set, a key with that prefix will be prioritized.
342
220
  *
343
- * @param array|object $item
344
- * @param string $field
345
- * @param bool $lenient If true, return null instead of erroring when field is not found.
346
- * @return string|null
221
+ * @param object $item
222
+ * @param string $field
223
+ * @return string
347
224
  */
348
- private function find_item_key( $item, $field, $lenient = false ) {
225
+ private function find_item_key( $item, $field ) {
349
226
  foreach ( [ $field, $this->prefix . '_' . $field ] as $maybe_key ) {
350
- if (
351
- ( is_object( $item ) && ( property_exists( $item, $maybe_key ) || isset( $item->$maybe_key ) ) ) ||
352
- ( is_array( $item ) && array_key_exists( $maybe_key, $item ) )
353
- ) {
227
+ if ( ( is_object( $item ) && ( property_exists( $item, $maybe_key ) || isset( $item->$maybe_key ) ) ) || ( is_array( $item ) && array_key_exists( $maybe_key, $item ) ) ) {
354
228
  $key = $maybe_key;
355
229
  break;
356
230
  }
357
231
  }
358
232
 
359
233
  if ( ! isset( $key ) ) {
360
- if ( $lenient ) {
361
- return null;
362
- }
363
234
  WP_CLI::error( "Invalid field: $field." );
364
235
  }
365
236
 
@@ -369,21 +240,15 @@ class Formatter {
369
240
  /**
370
241
  * Show multiple fields of an object.
371
242
  *
372
- * @param iterable $data Data to display
373
- * @param string $format Format to display the data in
374
- * @param bool|array $ascii_pre_colorized Optional. A boolean or an array of booleans to pass to `show_table()` if the item in the table is pre-colorized. Default false.
243
+ * @param object|array $data Data to display
244
+ * @param string $format Format to display the data in
245
+ * @param bool|array $ascii_pre_colorized Optional. A boolean or an array of booleans to pass to `show_table()` if the item in the table is pre-colorized. Default false.
375
246
  */
376
- private function show_multiple_fields( $data, $format, $ascii_pre_colorized = false ): void {
247
+ private function show_multiple_fields( $data, $format, $ascii_pre_colorized = false ) {
377
248
 
378
249
  $true_fields = [];
379
250
  foreach ( $this->args['fields'] as $field ) {
380
- $key = $this->find_item_key( $data, $field, true );
381
- if ( null === $key ) {
382
- // Field doesn't exist, show warning
383
- WP_CLI::warning( "Field not found in item: $field." );
384
- } else {
385
- $true_fields[] = $key;
386
- }
251
+ $true_fields[] = $this->find_item_key( $data, $field );
387
252
  }
388
253
 
389
254
  foreach ( $data as $key => $value ) {
@@ -396,17 +261,11 @@ class Formatter {
396
261
  }
397
262
  }
398
263
 
399
- $ordered_data = [];
400
-
401
- foreach ( $true_fields as $field ) {
402
- $ordered_data[ $field ] = ( ( (array) $data )[ $field ] );
403
- }
404
-
405
264
  switch ( $format ) {
406
265
 
407
266
  case 'table':
408
267
  case 'csv':
409
- $rows = $this->assoc_array_to_rows( $ordered_data );
268
+ $rows = $this->assoc_array_to_rows( $data );
410
269
  $fields = [ 'Field', 'Value' ];
411
270
  if ( 'table' === $format ) {
412
271
  self::show_table( $rows, $fields, $ascii_pre_colorized );
@@ -418,7 +277,7 @@ class Formatter {
418
277
  case 'yaml':
419
278
  case 'json':
420
279
  WP_CLI::print_value(
421
- $ordered_data,
280
+ $data,
422
281
  [
423
282
  'format' => $format,
424
283
  ]
@@ -434,11 +293,11 @@ class Formatter {
434
293
  /**
435
294
  * Show items in a \cli\Table.
436
295
  *
437
- * @param iterable $items Items.
438
- * @param array $fields Fields.
296
+ * @param array $items
297
+ * @param array $fields
439
298
  * @param bool|array $ascii_pre_colorized Optional. A boolean or an array of booleans to pass to `Table::setAsciiPreColorized()` if items in the table are pre-colorized. Default false.
440
299
  */
441
- private function show_table( $items, $fields, $ascii_pre_colorized = false ) {
300
+ private static function show_table( $items, $fields, $ascii_pre_colorized = false ) {
442
301
  $table = new Table();
443
302
 
444
303
  $enabled = WP_CLI::get_runner()->in_color();
@@ -448,9 +307,6 @@ class Formatter {
448
307
 
449
308
  $table->setAsciiPreColorized( $ascii_pre_colorized );
450
309
  $table->setHeaders( $fields );
451
- $table->setAlignments(
452
- $this->args['alignments']
453
- );
454
310
 
455
311
  foreach ( $items as $item ) {
456
312
  $table->addRow( array_values( Utils\pick_fields( $item, $fields ) ) );
@@ -468,7 +324,7 @@ class Formatter {
468
324
  /**
469
325
  * Format an associative array as a table.
470
326
  *
471
- * @param iterable $fields Fields and values to format
327
+ * @param array $fields Fields and values to format
472
328
  * @return array
473
329
  */
474
330
  private function assoc_array_to_rows( $fields ) {
@@ -480,11 +336,6 @@ class Formatter {
480
336
  $value = json_encode( $value );
481
337
  }
482
338
 
483
- // Truncate large values for table/CSV output performance
484
- if ( is_string( $value ) && strlen( $value ) > self::MAX_CELL_WIDTH ) {
485
- $value = substr( $value, 0, self::MAX_CELL_WIDTH ) . '...';
486
- }
487
-
488
339
  $rows[] = (object) [
489
340
  'Field' => $field,
490
341
  'Value' => $value,
@@ -495,36 +346,21 @@ class Formatter {
495
346
  }
496
347
 
497
348
  /**
498
- * Transforms item values for string-based output formats (table/CSV).
349
+ * Transforms objects and arrays to JSON as necessary
499
350
  *
500
- * Converts complex types to strings:
501
- * - Objects and arrays are converted to JSON strings
502
- * - Booleans are converted to "true" or "false"
503
- *
504
- * @param array|object $item
351
+ * @param mixed $item
505
352
  * @return mixed
506
353
  */
507
354
  public function transform_item_values_to_json( $item ) {
508
355
  foreach ( $this->args['fields'] as $field ) {
509
- $true_field = $this->find_item_key( $item, $field, true );
510
- if ( null === $true_field ) {
511
- // Field doesn't exist in this item, skip it
512
- continue;
513
- }
514
- $value = is_object( $item ) ? $item->$true_field : $item[ $true_field ];
356
+ $true_field = $this->find_item_key( $item, $field );
357
+ $value = is_object( $item ) ? $item->$true_field : $item[ $true_field ];
515
358
  if ( is_array( $value ) || is_object( $value ) ) {
516
359
  if ( is_object( $item ) ) {
517
360
  $item->$true_field = json_encode( $value );
518
361
  } elseif ( is_array( $item ) ) {
519
362
  $item[ $true_field ] = json_encode( $value );
520
363
  }
521
- } elseif ( is_bool( $value ) ) {
522
- // Convert boolean to string representation for table/CSV display
523
- if ( is_object( $item ) ) {
524
- $item->$true_field = $value ? 'true' : 'false';
525
- } elseif ( is_array( $item ) ) {
526
- $item[ $true_field ] = $value ? 'true' : 'false';
527
- }
528
364
  }
529
365
  }
530
366
  return $item;
@@ -315,7 +315,7 @@ class Inflector {
315
315
  * @return string The tableized word.
316
316
  */
317
317
  public static function tableize( $word ) {
318
- return strtolower( (string) preg_replace( '~(?<=\\w)([A-Z])~', '_$1', $word ) );
318
+ return strtolower( preg_replace( '~(?<=\\w)([A-Z])~', '_$1', $word ) );
319
319
  }
320
320
 
321
321
  /**
@@ -366,7 +366,7 @@ class Inflector {
366
366
  * @return string The string with all delimiter-separated words capitalized.
367
367
  */
368
368
  public static function ucwords( $string, $delimiters = " \n\t\r\0\x0B-" ) {
369
- return (string) preg_replace_callback(
369
+ return preg_replace_callback(
370
370
  '/[^' . preg_quote( $delimiters, '/' ) . ']+/',
371
371
  function ( $matches ) {
372
372
  return ucfirst( $matches[0] );
@@ -486,7 +486,7 @@ class Inflector {
486
486
 
487
487
  foreach ( self::$plural['rules'] as $rule => $replacement ) {
488
488
  if ( preg_match( $rule, $word ) ) {
489
- self::$cache['pluralize'][ $word ] = (string) preg_replace( $rule, $replacement, $word );
489
+ self::$cache['pluralize'][ $word ] = preg_replace( $rule, $replacement, $word );
490
490
 
491
491
  return self::$cache['pluralize'][ $word ];
492
492
  }
@@ -542,7 +542,7 @@ class Inflector {
542
542
 
543
543
  foreach ( self::$singular['rules'] as $rule => $replacement ) {
544
544
  if ( preg_match( $rule, $word ) ) {
545
- self::$cache['singularize'][ $word ] = (string) preg_replace( $rule, $replacement, $word );
545
+ self::$cache['singularize'][ $word ] = preg_replace( $rule, $replacement, $word );
546
546
 
547
547
  return self::$cache['singularize'][ $word ];
548
548
  }
@@ -10,8 +10,6 @@ use WP_CLI;
10
10
 
11
11
  /**
12
12
  * Allows incrementally reading and parsing lines from a CSV file.
13
- *
14
- * @implements \Iterator<int, string>
15
13
  */
16
14
  class CSV implements Countable, Iterator {
17
15
 
@@ -83,14 +81,11 @@ class CSV implements Countable, Iterator {
83
81
  }
84
82
  }
85
83
 
86
- /**
87
- * @return int<0, max>
88
- */
89
84
  #[ReturnTypeWillChange]
90
85
  public function count() {
91
86
  $file = new SplFileObject( $this->filename, 'r' );
92
87
  $file->seek( PHP_INT_MAX );
93
- return max( 0, $file->key() + 1 );
88
+ return $file->key() + 1;
94
89
  }
95
90
 
96
91
  #[ReturnTypeWillChange]
@@ -8,8 +8,6 @@ use Iterator;
8
8
  * Iterates over results of a query, split into many queries via LIMIT and OFFSET
9
9
  *
10
10
  * @source https://gist.github.com/4060005
11
- *
12
- * @implements \Iterator<int, mixed>
13
11
  */
14
12
  class Query implements Iterator {
15
13
 
@@ -58,7 +56,7 @@ class Query implements Iterator {
58
56
  * longer be returned by the original query, the offset must be reduced to
59
57
  * iterate over all remaining rows.
60
58
  */
61
- private function adjust_offset_for_shrinking_result_set(): void {
59
+ private function adjust_offset_for_shrinking_result_set() {
62
60
  if ( empty( $this->count_query ) ) {
63
61
  return;
64
62
  }
@@ -78,19 +78,13 @@ class Table extends Query {
78
78
  $conditions = [];
79
79
  foreach ( $where as $key => $value ) {
80
80
  if ( is_array( $value ) ) {
81
- /**
82
- * @var array<string> $value
83
- * @var string $values
84
- */
85
- $values = esc_sql( implode( ',', $value ) );
86
- $conditions[] = $key . ' IN (' . $values . ')';
81
+ $conditions[] = $key . ' IN (' . esc_sql( implode( ',', $value ) ) . ')';
87
82
  } elseif ( is_numeric( $key ) ) {
88
83
  $conditions[] = $value;
89
84
  } else {
90
85
  $conditions[] = $key . $wpdb->prepare( ' = %s', $value );
91
86
  }
92
87
  }
93
- /** @var array<string> $conditions */
94
88
  $where = implode( ' AND ', $conditions );
95
89
  }
96
90
  return $where;
@@ -6,8 +6,6 @@ use IteratorIterator;
6
6
 
7
7
  /**
8
8
  * Applies one or more callbacks to an item before returning it.
9
- *
10
- * @phpstan-extends IteratorIterator<int, mixed, \Iterator>
11
9
  */
12
10
  class Transform extends IteratorIterator {
13
11
 
@@ -13,25 +13,10 @@ abstract class Base {
13
13
 
14
14
  protected $in_color = false;
15
15
 
16
- /**
17
- * Informational message.
18
- *
19
- * @param string $message Message to write.
20
- */
21
16
  abstract public function info( $message );
22
17
 
23
- /**
24
- * Success message.
25
- *
26
- * @param string $message Message to write.
27
- */
28
18
  abstract public function success( $message );
29
19
 
30
- /**
31
- * Warning message.
32
- *
33
- * @param string $message Message to write.
34
- */
35
20
  abstract public function warning( $message );
36
21
 
37
22
  /**
@@ -2,6 +2,8 @@
2
2
 
3
3
  namespace WP_CLI\Loggers;
4
4
 
5
+ use WP_CLI;
6
+
5
7
  /**
6
8
  * Quiet logger only logs errors.
7
9
  */
@@ -18,9 +20,8 @@ class Quiet extends Base {
18
20
  * Informational messages aren't logged.
19
21
  *
20
22
  * @param string $message Message to write.
21
- * @param bool $newline Optional. Whether to append a newline to the end of the message. Default true.
22
23
  */
23
- public function info( $message, $newline = true ) {
24
+ public function info( $message ) {
24
25
  // Nothing.
25
26
  }
26
27
 
@@ -20,10 +20,9 @@ class Regular extends Base {
20
20
  * Write an informational message to STDOUT.
21
21
  *
22
22
  * @param string $message Message to write.
23
- * @param bool $newline Optional. Whether to append a newline to the end of the message. Default true.
24
23
  */
25
- public function info( $message, $newline = true ) {
26
- $this->write( STDOUT, $message . ( $newline ? "\n" : '' ) );
24
+ public function info( $message ) {
25
+ $this->write( STDOUT, $message . "\n" );
27
26
  }
28
27
 
29
28
  /**
@@ -56,7 +55,7 @@ class Regular extends Base {
56
55
  /**
57
56
  * Similar to error( $message ), but outputs $message in a red box.
58
57
  *
59
- * @param non-empty-array<string> $message_lines Message to write.
58
+ * @param array $message_lines Message to write.
60
59
  */
61
60
  public function error_multi_line( $message_lines ) {
62
61
  // Convert tabs to four spaces, as some shells will output the tabs as variable-length.
@@ -4,10 +4,6 @@ namespace WP_CLI;
4
4
 
5
5
  /**
6
6
  * Escape route for not doing anything.
7
- *
8
- * @method void display(bool $finish = false)
9
- * @method void tick(int $increment = 1, ?string $msg = null)
10
- * @method void finish()
11
7
  */
12
8
  final class NoOp {
13
9