@invarn/cibuild 2.9.5 → 2.9.7

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 (553) hide show
  1. package/dist/chunk-35SI42CD.mjs +1 -0
  2. package/dist/chunk-IC45KVLJ.mjs +1 -0
  3. package/dist/chunk-XDY4V23V.mjs +1 -0
  4. package/dist/cli.cjs +14 -14
  5. package/dist/commands.mjs +1 -0
  6. package/dist/lib.mjs +3934 -0
  7. package/package.json +6 -10
  8. package/dist/src/cli.d.ts +0 -3
  9. package/dist/src/cli.d.ts.map +0 -1
  10. package/dist/src/cli.js +0 -399
  11. package/dist/src/commands/a-credential-target-follows-the-flavor-source-set.test.d.ts +0 -38
  12. package/dist/src/commands/a-credential-target-follows-the-flavor-source-set.test.d.ts.map +0 -1
  13. package/dist/src/commands/a-credential-target-follows-the-flavor-source-set.test.js +0 -222
  14. package/dist/src/commands/a-credential-two-workflows-cannot-share-is-declared-per-workflow.test.d.ts +0 -41
  15. package/dist/src/commands/a-credential-two-workflows-cannot-share-is-declared-per-workflow.test.d.ts.map +0 -1
  16. package/dist/src/commands/a-credential-two-workflows-cannot-share-is-declared-per-workflow.test.js +0 -324
  17. package/dist/src/commands/a-properties-stand-in-declares-the-keys-the-build-reads.test.d.ts +0 -2
  18. package/dist/src/commands/a-properties-stand-in-declares-the-keys-the-build-reads.test.d.ts.map +0 -1
  19. package/dist/src/commands/a-properties-stand-in-declares-the-keys-the-build-reads.test.js +0 -382
  20. package/dist/src/commands/an-already-stored-value-does-not-answer-the-target-question.test.d.ts +0 -29
  21. package/dist/src/commands/an-already-stored-value-does-not-answer-the-target-question.test.d.ts.map +0 -1
  22. package/dist/src/commands/an-already-stored-value-does-not-answer-the-target-question.test.js +0 -160
  23. package/dist/src/commands/android-gms-guard.test.d.ts +0 -9
  24. package/dist/src/commands/android-gms-guard.test.d.ts.map +0 -1
  25. package/dist/src/commands/android-gms-guard.test.js +0 -78
  26. package/dist/src/commands/android-java-version.test.d.ts +0 -12
  27. package/dist/src/commands/android-java-version.test.d.ts.map +0 -1
  28. package/dist/src/commands/android-java-version.test.js +0 -209
  29. package/dist/src/commands/android-scanner-java.test.d.ts +0 -2
  30. package/dist/src/commands/android-scanner-java.test.d.ts.map +0 -1
  31. package/dist/src/commands/android-scanner-java.test.js +0 -130
  32. package/dist/src/commands/android-scanner.d.ts +0 -250
  33. package/dist/src/commands/android-scanner.d.ts.map +0 -1
  34. package/dist/src/commands/android-scanner.js +0 -1639
  35. package/dist/src/commands/build.d.ts +0 -215
  36. package/dist/src/commands/build.d.ts.map +0 -1
  37. package/dist/src/commands/build.js +0 -1433
  38. package/dist/src/commands/build.test.d.ts +0 -13
  39. package/dist/src/commands/build.test.d.ts.map +0 -1
  40. package/dist/src/commands/build.test.js +0 -121
  41. package/dist/src/commands/detect-platform.d.ts +0 -13
  42. package/dist/src/commands/detect-platform.d.ts.map +0 -1
  43. package/dist/src/commands/detect-platform.js +0 -51
  44. package/dist/src/commands/detect-project.d.ts +0 -7
  45. package/dist/src/commands/detect-project.d.ts.map +0 -1
  46. package/dist/src/commands/detect-project.js +0 -12
  47. package/dist/src/commands/each-flavor-is-asked-for-its-own-properties-file.test.d.ts +0 -26
  48. package/dist/src/commands/each-flavor-is-asked-for-its-own-properties-file.test.d.ts.map +0 -1
  49. package/dist/src/commands/each-flavor-is-asked-for-its-own-properties-file.test.js +0 -196
  50. package/dist/src/commands/edit.d.ts +0 -12
  51. package/dist/src/commands/edit.d.ts.map +0 -1
  52. package/dist/src/commands/edit.js +0 -652
  53. package/dist/src/commands/edit.test.d.ts +0 -6
  54. package/dist/src/commands/edit.test.d.ts.map +0 -1
  55. package/dist/src/commands/edit.test.js +0 -45
  56. package/dist/src/commands/fidelity-trim.d.ts +0 -13
  57. package/dist/src/commands/fidelity-trim.d.ts.map +0 -1
  58. package/dist/src/commands/fidelity-trim.js +0 -21
  59. package/dist/src/commands/fidelity-trim.test.d.ts +0 -8
  60. package/dist/src/commands/fidelity-trim.test.d.ts.map +0 -1
  61. package/dist/src/commands/fidelity-trim.test.js +0 -79
  62. package/dist/src/commands/file-secret-collector.d.ts +0 -50
  63. package/dist/src/commands/file-secret-collector.d.ts.map +0 -1
  64. package/dist/src/commands/file-secret-collector.js +0 -217
  65. package/dist/src/commands/flavors-a-convention-plugin-creates-are-still-found.test.d.ts +0 -38
  66. package/dist/src/commands/flavors-a-convention-plugin-creates-are-still-found.test.d.ts.map +0 -1
  67. package/dist/src/commands/flavors-a-convention-plugin-creates-are-still-found.test.js +0 -300
  68. package/dist/src/commands/github-workflow.d.ts +0 -5
  69. package/dist/src/commands/github-workflow.d.ts.map +0 -1
  70. package/dist/src/commands/github-workflow.js +0 -45
  71. package/dist/src/commands/index.d.ts +0 -33
  72. package/dist/src/commands/index.d.ts.map +0 -1
  73. package/dist/src/commands/index.js +0 -33
  74. package/dist/src/commands/init.d.ts +0 -20
  75. package/dist/src/commands/init.d.ts.map +0 -1
  76. package/dist/src/commands/init.js +0 -264
  77. package/dist/src/commands/ios-scanner.d.ts +0 -104
  78. package/dist/src/commands/ios-scanner.d.ts.map +0 -1
  79. package/dist/src/commands/ios-scanner.js +0 -492
  80. package/dist/src/commands/ios-scheme-ranking.test.d.ts +0 -2
  81. package/dist/src/commands/ios-scheme-ranking.test.d.ts.map +0 -1
  82. package/dist/src/commands/ios-scheme-ranking.test.js +0 -264
  83. package/dist/src/commands/local-properties-reaches-every-workflow.test.d.ts +0 -30
  84. package/dist/src/commands/local-properties-reaches-every-workflow.test.d.ts.map +0 -1
  85. package/dist/src/commands/local-properties-reaches-every-workflow.test.js +0 -146
  86. package/dist/src/commands/reset.d.ts +0 -7
  87. package/dist/src/commands/reset.d.ts.map +0 -1
  88. package/dist/src/commands/reset.js +0 -81
  89. package/dist/src/commands/run.d.ts +0 -22
  90. package/dist/src/commands/run.d.ts.map +0 -1
  91. package/dist/src/commands/run.js +0 -141
  92. package/dist/src/commands/secrets-sync-workflow.d.ts +0 -15
  93. package/dist/src/commands/secrets-sync-workflow.d.ts.map +0 -1
  94. package/dist/src/commands/secrets-sync-workflow.js +0 -255
  95. package/dist/src/commands/secrets-upload.d.ts +0 -21
  96. package/dist/src/commands/secrets-upload.d.ts.map +0 -1
  97. package/dist/src/commands/secrets-upload.js +0 -177
  98. package/dist/src/commands/secrets-upload.test.d.ts +0 -5
  99. package/dist/src/commands/secrets-upload.test.d.ts.map +0 -1
  100. package/dist/src/commands/secrets-upload.test.js +0 -60
  101. package/dist/src/commands/validate.d.ts +0 -10
  102. package/dist/src/commands/validate.d.ts.map +0 -1
  103. package/dist/src/commands/validate.js +0 -46
  104. package/dist/src/config.d.ts +0 -3
  105. package/dist/src/config.d.ts.map +0 -1
  106. package/dist/src/config.js +0 -47
  107. package/dist/src/envman/cli.d.ts +0 -21
  108. package/dist/src/envman/cli.d.ts.map +0 -1
  109. package/dist/src/envman/cli.js +0 -240
  110. package/dist/src/envman/envman.d.ts +0 -83
  111. package/dist/src/envman/envman.d.ts.map +0 -1
  112. package/dist/src/envman/envman.js +0 -361
  113. package/dist/src/envman/envman.test.d.ts +0 -5
  114. package/dist/src/envman/envman.test.d.ts.map +0 -1
  115. package/dist/src/envman/envman.test.js +0 -236
  116. package/dist/src/envman/envstore-round-trip.test.d.ts +0 -27
  117. package/dist/src/envman/envstore-round-trip.test.d.ts.map +0 -1
  118. package/dist/src/envman/envstore-round-trip.test.js +0 -130
  119. package/dist/src/envman/index.d.ts +0 -23
  120. package/dist/src/envman/index.d.ts.map +0 -1
  121. package/dist/src/envman/index.js +0 -23
  122. package/dist/src/envman/shim.d.ts +0 -16
  123. package/dist/src/envman/shim.d.ts.map +0 -1
  124. package/dist/src/envman/shim.js +0 -66
  125. package/dist/src/envman/types.d.ts +0 -55
  126. package/dist/src/envman/types.d.ts.map +0 -1
  127. package/dist/src/envman/types.js +0 -12
  128. package/dist/src/lib.d.ts +0 -33
  129. package/dist/src/lib.d.ts.map +0 -1
  130. package/dist/src/lib.js +0 -37
  131. package/dist/src/pipeline.d.ts +0 -3
  132. package/dist/src/pipeline.d.ts.map +0 -1
  133. package/dist/src/pipeline.js +0 -57
  134. package/dist/src/runner-node-step.test.d.ts +0 -12
  135. package/dist/src/runner-node-step.test.d.ts.map +0 -1
  136. package/dist/src/runner-node-step.test.js +0 -61
  137. package/dist/src/runner.d.ts +0 -31
  138. package/dist/src/runner.d.ts.map +0 -1
  139. package/dist/src/runner.js +0 -240
  140. package/dist/src/shared/detect-project.d.ts +0 -57
  141. package/dist/src/shared/detect-project.d.ts.map +0 -1
  142. package/dist/src/shared/detect-project.js +0 -219
  143. package/dist/src/shared/detect-project.test.d.ts +0 -2
  144. package/dist/src/shared/detect-project.test.d.ts.map +0 -1
  145. package/dist/src/shared/detect-project.test.js +0 -161
  146. package/dist/src/shared/git.d.ts +0 -25
  147. package/dist/src/shared/git.d.ts.map +0 -1
  148. package/dist/src/shared/git.js +0 -53
  149. package/dist/src/shared/git.test.d.ts +0 -9
  150. package/dist/src/shared/git.test.d.ts.map +0 -1
  151. package/dist/src/shared/git.test.js +0 -66
  152. package/dist/src/shared/gitignore.d.ts +0 -6
  153. package/dist/src/shared/gitignore.d.ts.map +0 -1
  154. package/dist/src/shared/gitignore.js +0 -26
  155. package/dist/src/shared/gradle-settings.d.ts +0 -49
  156. package/dist/src/shared/gradle-settings.d.ts.map +0 -1
  157. package/dist/src/shared/gradle-settings.js +0 -138
  158. package/dist/src/shared/gradle-settings.test.d.ts +0 -2
  159. package/dist/src/shared/gradle-settings.test.d.ts.map +0 -1
  160. package/dist/src/shared/gradle-settings.test.js +0 -65
  161. package/dist/src/shared/prompts.d.ts +0 -30
  162. package/dist/src/shared/prompts.d.ts.map +0 -1
  163. package/dist/src/shared/prompts.js +0 -121
  164. package/dist/src/shared/xcode-container.test.d.ts +0 -2
  165. package/dist/src/shared/xcode-container.test.d.ts.map +0 -1
  166. package/dist/src/shared/xcode-container.test.js +0 -123
  167. package/dist/src/step-marker.d.ts +0 -12
  168. package/dist/src/step-marker.d.ts.map +0 -1
  169. package/dist/src/step-marker.js +0 -29
  170. package/dist/src/step-marker.test.d.ts +0 -11
  171. package/dist/src/step-marker.test.d.ts.map +0 -1
  172. package/dist/src/step-marker.test.js +0 -45
  173. package/dist/src/types.d.ts +0 -58
  174. package/dist/src/types.d.ts.map +0 -1
  175. package/dist/src/types.js +0 -2
  176. package/dist/src/yaml/a-cache-path-must-not-swallow-a-credential.test.d.ts +0 -28
  177. package/dist/src/yaml/a-cache-path-must-not-swallow-a-credential.test.d.ts.map +0 -1
  178. package/dist/src/yaml/a-cache-path-must-not-swallow-a-credential.test.js +0 -223
  179. package/dist/src/yaml/a-declared-secret-reaches-the-file-step.test.d.ts +0 -20
  180. package/dist/src/yaml/a-declared-secret-reaches-the-file-step.test.d.ts.map +0 -1
  181. package/dist/src/yaml/a-declared-secret-reaches-the-file-step.test.js +0 -201
  182. package/dist/src/yaml/a-declared-slot-may-name-the-workflow-it-belongs-to.test.d.ts +0 -37
  183. package/dist/src/yaml/a-declared-slot-may-name-the-workflow-it-belongs-to.test.d.ts.map +0 -1
  184. package/dist/src/yaml/a-declared-slot-may-name-the-workflow-it-belongs-to.test.js +0 -255
  185. package/dist/src/yaml/a-missing-credential-is-loud.test.d.ts +0 -32
  186. package/dist/src/yaml/a-missing-credential-is-loud.test.d.ts.map +0 -1
  187. package/dist/src/yaml/a-missing-credential-is-loud.test.js +0 -301
  188. package/dist/src/yaml/a-runtime-requirement-names-a-real-provider.test.d.ts +0 -18
  189. package/dist/src/yaml/a-runtime-requirement-names-a-real-provider.test.d.ts.map +0 -1
  190. package/dist/src/yaml/a-runtime-requirement-names-a-real-provider.test.js +0 -66
  191. package/dist/src/yaml/a-scoped-slot-must-name-a-workflow-the-pipeline-has.test.d.ts +0 -34
  192. package/dist/src/yaml/a-scoped-slot-must-name-a-workflow-the-pipeline-has.test.d.ts.map +0 -1
  193. package/dist/src/yaml/a-scoped-slot-must-name-a-workflow-the-pipeline-has.test.js +0 -218
  194. package/dist/src/yaml/a-value-this-instance-stored-is-a-value-it-has.test.d.ts +0 -27
  195. package/dist/src/yaml/a-value-this-instance-stored-is-a-value-it-has.test.d.ts.map +0 -1
  196. package/dist/src/yaml/a-value-this-instance-stored-is-a-value-it-has.test.js +0 -126
  197. package/dist/src/yaml/bitrise-compat.d.ts +0 -65
  198. package/dist/src/yaml/bitrise-compat.d.ts.map +0 -1
  199. package/dist/src/yaml/bitrise-compat.js +0 -206
  200. package/dist/src/yaml/bitrise-compat.test.d.ts +0 -5
  201. package/dist/src/yaml/bitrise-compat.test.d.ts.map +0 -1
  202. package/dist/src/yaml/bitrise-compat.test.js +0 -347
  203. package/dist/src/yaml/cache-key-missing-file.test.d.ts +0 -12
  204. package/dist/src/yaml/cache-key-missing-file.test.d.ts.map +0 -1
  205. package/dist/src/yaml/cache-key-missing-file.test.js +0 -116
  206. package/dist/src/yaml/converter.d.ts +0 -103
  207. package/dist/src/yaml/converter.d.ts.map +0 -1
  208. package/dist/src/yaml/converter.js +0 -420
  209. package/dist/src/yaml/converter.test.d.ts +0 -5
  210. package/dist/src/yaml/converter.test.d.ts.map +0 -1
  211. package/dist/src/yaml/converter.test.js +0 -548
  212. package/dist/src/yaml/e2e.test.d.ts +0 -6
  213. package/dist/src/yaml/e2e.test.d.ts.map +0 -1
  214. package/dist/src/yaml/e2e.test.js +0 -446
  215. package/dist/src/yaml/env-resolver.d.ts +0 -218
  216. package/dist/src/yaml/env-resolver.d.ts.map +0 -1
  217. package/dist/src/yaml/env-resolver.js +0 -591
  218. package/dist/src/yaml/env-resolver.test.d.ts +0 -5
  219. package/dist/src/yaml/env-resolver.test.d.ts.map +0 -1
  220. package/dist/src/yaml/env-resolver.test.js +0 -502
  221. package/dist/src/yaml/every-build-log-witnesses-the-commit-on-disk.test.d.ts +0 -16
  222. package/dist/src/yaml/every-build-log-witnesses-the-commit-on-disk.test.d.ts.map +0 -1
  223. package/dist/src/yaml/every-build-log-witnesses-the-commit-on-disk.test.js +0 -126
  224. package/dist/src/yaml/fidelity-input-digest.d.ts +0 -37
  225. package/dist/src/yaml/fidelity-input-digest.d.ts.map +0 -1
  226. package/dist/src/yaml/fidelity-input-digest.js +0 -208
  227. package/dist/src/yaml/fidelity-input-digest.test.d.ts +0 -2
  228. package/dist/src/yaml/fidelity-input-digest.test.d.ts.map +0 -1
  229. package/dist/src/yaml/fidelity-input-digest.test.js +0 -167
  230. package/dist/src/yaml/fidelity-manifest.d.ts +0 -126
  231. package/dist/src/yaml/fidelity-manifest.d.ts.map +0 -1
  232. package/dist/src/yaml/fidelity-manifest.js +0 -134
  233. package/dist/src/yaml/fidelity-manifest.test.d.ts +0 -12
  234. package/dist/src/yaml/fidelity-manifest.test.d.ts.map +0 -1
  235. package/dist/src/yaml/fidelity-manifest.test.js +0 -251
  236. package/dist/src/yaml/interactive-prompts.d.ts +0 -71
  237. package/dist/src/yaml/interactive-prompts.d.ts.map +0 -1
  238. package/dist/src/yaml/interactive-prompts.js +0 -260
  239. package/dist/src/yaml/meta-helpers.d.ts +0 -28
  240. package/dist/src/yaml/meta-helpers.d.ts.map +0 -1
  241. package/dist/src/yaml/meta-helpers.js +0 -46
  242. package/dist/src/yaml/missing-env-handler.d.ts +0 -45
  243. package/dist/src/yaml/missing-env-handler.d.ts.map +0 -1
  244. package/dist/src/yaml/missing-env-handler.js +0 -64
  245. package/dist/src/yaml/parser.d.ts +0 -33
  246. package/dist/src/yaml/parser.d.ts.map +0 -1
  247. package/dist/src/yaml/parser.js +0 -148
  248. package/dist/src/yaml/parser.test.d.ts +0 -5
  249. package/dist/src/yaml/parser.test.d.ts.map +0 -1
  250. package/dist/src/yaml/parser.test.js +0 -83
  251. package/dist/src/yaml/pipeline-with-secrets.d.ts +0 -25
  252. package/dist/src/yaml/pipeline-with-secrets.d.ts.map +0 -1
  253. package/dist/src/yaml/pipeline-with-secrets.js +0 -76
  254. package/dist/src/yaml/platform-detector.d.ts +0 -83
  255. package/dist/src/yaml/platform-detector.d.ts.map +0 -1
  256. package/dist/src/yaml/platform-detector.js +0 -189
  257. package/dist/src/yaml/platform-detector.test.d.ts +0 -5
  258. package/dist/src/yaml/platform-detector.test.d.ts.map +0 -1
  259. package/dist/src/yaml/platform-detector.test.js +0 -525
  260. package/dist/src/yaml/preflight-validation.d.ts +0 -29
  261. package/dist/src/yaml/preflight-validation.d.ts.map +0 -1
  262. package/dist/src/yaml/preflight-validation.js +0 -21
  263. package/dist/src/yaml/secrets-manager.d.ts +0 -87
  264. package/dist/src/yaml/secrets-manager.d.ts.map +0 -1
  265. package/dist/src/yaml/secrets-manager.js +0 -230
  266. package/dist/src/yaml/shell-assignments.d.ts +0 -40
  267. package/dist/src/yaml/shell-assignments.d.ts.map +0 -1
  268. package/dist/src/yaml/shell-assignments.js +0 -77
  269. package/dist/src/yaml/step-validator-check-failure.test.d.ts +0 -24
  270. package/dist/src/yaml/step-validator-check-failure.test.d.ts.map +0 -1
  271. package/dist/src/yaml/step-validator-check-failure.test.js +0 -130
  272. package/dist/src/yaml/step-validator-self-assigned.test.d.ts +0 -23
  273. package/dist/src/yaml/step-validator-self-assigned.test.d.ts.map +0 -1
  274. package/dist/src/yaml/step-validator-self-assigned.test.js +0 -191
  275. package/dist/src/yaml/step-validator.d.ts +0 -67
  276. package/dist/src/yaml/step-validator.d.ts.map +0 -1
  277. package/dist/src/yaml/step-validator.js +0 -466
  278. package/dist/src/yaml/step-validator.test.d.ts +0 -18
  279. package/dist/src/yaml/step-validator.test.d.ts.map +0 -1
  280. package/dist/src/yaml/step-validator.test.js +0 -140
  281. package/dist/src/yaml/steps/android-sign.d.ts +0 -35
  282. package/dist/src/yaml/steps/android-sign.d.ts.map +0 -1
  283. package/dist/src/yaml/steps/android-sign.js +0 -147
  284. package/dist/src/yaml/steps/android-variant-resolution.test.d.ts +0 -2
  285. package/dist/src/yaml/steps/android-variant-resolution.test.d.ts.map +0 -1
  286. package/dist/src/yaml/steps/android-variant-resolution.test.js +0 -260
  287. package/dist/src/yaml/steps/android-version.d.ts +0 -26
  288. package/dist/src/yaml/steps/android-version.d.ts.map +0 -1
  289. package/dist/src/yaml/steps/android-version.js +0 -128
  290. package/dist/src/yaml/steps/android-version.test.d.ts +0 -5
  291. package/dist/src/yaml/steps/android-version.test.d.ts.map +0 -1
  292. package/dist/src/yaml/steps/android-version.test.js +0 -196
  293. package/dist/src/yaml/steps/android.d.ts +0 -156
  294. package/dist/src/yaml/steps/android.d.ts.map +0 -1
  295. package/dist/src/yaml/steps/android.js +0 -1092
  296. package/dist/src/yaml/steps/app-store-deploy.d.ts +0 -48
  297. package/dist/src/yaml/steps/app-store-deploy.d.ts.map +0 -1
  298. package/dist/src/yaml/steps/app-store-deploy.js +0 -167
  299. package/dist/src/yaml/steps/base.d.ts +0 -263
  300. package/dist/src/yaml/steps/base.d.ts.map +0 -1
  301. package/dist/src/yaml/steps/base.js +0 -380
  302. package/dist/src/yaml/steps/bitrise-android-tools.d.ts +0 -26
  303. package/dist/src/yaml/steps/bitrise-android-tools.d.ts.map +0 -1
  304. package/dist/src/yaml/steps/bitrise-android-tools.js +0 -200
  305. package/dist/src/yaml/steps/bitrise-android-tools.test.d.ts +0 -5
  306. package/dist/src/yaml/steps/bitrise-android-tools.test.d.ts.map +0 -1
  307. package/dist/src/yaml/steps/bitrise-android-tools.test.js +0 -280
  308. package/dist/src/yaml/steps/bitrise-apk-info.d.ts +0 -22
  309. package/dist/src/yaml/steps/bitrise-apk-info.d.ts.map +0 -1
  310. package/dist/src/yaml/steps/bitrise-apk-info.js +0 -144
  311. package/dist/src/yaml/steps/bitrise-apk-info.test.d.ts +0 -5
  312. package/dist/src/yaml/steps/bitrise-apk-info.test.d.ts.map +0 -1
  313. package/dist/src/yaml/steps/bitrise-apk-info.test.js +0 -331
  314. package/dist/src/yaml/steps/bitrise-slack.d.ts +0 -49
  315. package/dist/src/yaml/steps/bitrise-slack.d.ts.map +0 -1
  316. package/dist/src/yaml/steps/bitrise-slack.js +0 -280
  317. package/dist/src/yaml/steps/bitrise-slack.test.d.ts +0 -5
  318. package/dist/src/yaml/steps/bitrise-slack.test.d.ts.map +0 -1
  319. package/dist/src/yaml/steps/bitrise-slack.test.js +0 -484
  320. package/dist/src/yaml/steps/bitrise-ssh.d.ts +0 -27
  321. package/dist/src/yaml/steps/bitrise-ssh.d.ts.map +0 -1
  322. package/dist/src/yaml/steps/bitrise-ssh.js +0 -134
  323. package/dist/src/yaml/steps/bitrise-ssh.test.d.ts +0 -5
  324. package/dist/src/yaml/steps/bitrise-ssh.test.d.ts.map +0 -1
  325. package/dist/src/yaml/steps/bitrise-ssh.test.js +0 -205
  326. package/dist/src/yaml/steps/cache-pull-daemon.test.d.ts +0 -27
  327. package/dist/src/yaml/steps/cache-pull-daemon.test.d.ts.map +0 -1
  328. package/dist/src/yaml/steps/cache-pull-daemon.test.js +0 -212
  329. package/dist/src/yaml/steps/cache-pull-restore-roots.test.d.ts +0 -42
  330. package/dist/src/yaml/steps/cache-pull-restore-roots.test.d.ts.map +0 -1
  331. package/dist/src/yaml/steps/cache-pull-restore-roots.test.js +0 -209
  332. package/dist/src/yaml/steps/cache-push-daemon.test.d.ts +0 -27
  333. package/dist/src/yaml/steps/cache-push-daemon.test.d.ts.map +0 -1
  334. package/dist/src/yaml/steps/cache-push-daemon.test.js +0 -171
  335. package/dist/src/yaml/steps/cache.d.ts +0 -59
  336. package/dist/src/yaml/steps/cache.d.ts.map +0 -1
  337. package/dist/src/yaml/steps/cache.js +0 -1027
  338. package/dist/src/yaml/steps/capture-injection.d.ts +0 -30
  339. package/dist/src/yaml/steps/capture-injection.d.ts.map +0 -1
  340. package/dist/src/yaml/steps/capture-injection.js +0 -88
  341. package/dist/src/yaml/steps/capture-injection.test.d.ts +0 -2
  342. package/dist/src/yaml/steps/capture-injection.test.d.ts.map +0 -1
  343. package/dist/src/yaml/steps/capture-injection.test.js +0 -163
  344. package/dist/src/yaml/steps/cocoapods-deployment-floor.d.ts +0 -42
  345. package/dist/src/yaml/steps/cocoapods-deployment-floor.d.ts.map +0 -1
  346. package/dist/src/yaml/steps/cocoapods-deployment-floor.js +0 -140
  347. package/dist/src/yaml/steps/cocoapods-deployment-floor.test.d.ts +0 -11
  348. package/dist/src/yaml/steps/cocoapods-deployment-floor.test.d.ts.map +0 -1
  349. package/dist/src/yaml/steps/cocoapods-deployment-floor.test.js +0 -176
  350. package/dist/src/yaml/steps/cocoapods-install-emits-valid-bash.test.d.ts +0 -22
  351. package/dist/src/yaml/steps/cocoapods-install-emits-valid-bash.test.d.ts.map +0 -1
  352. package/dist/src/yaml/steps/cocoapods-install-emits-valid-bash.test.js +0 -97
  353. package/dist/src/yaml/steps/cocoapods-locked-bundler.test.d.ts +0 -17
  354. package/dist/src/yaml/steps/cocoapods-locked-bundler.test.d.ts.map +0 -1
  355. package/dist/src/yaml/steps/cocoapods-locked-bundler.test.js +0 -282
  356. package/dist/src/yaml/steps/cocoapods-skip-if-absent.test.d.ts +0 -17
  357. package/dist/src/yaml/steps/cocoapods-skip-if-absent.test.d.ts.map +0 -1
  358. package/dist/src/yaml/steps/cocoapods-skip-if-absent.test.js +0 -132
  359. package/dist/src/yaml/steps/envstore-loader.test.d.ts +0 -15
  360. package/dist/src/yaml/steps/envstore-loader.test.d.ts.map +0 -1
  361. package/dist/src/yaml/steps/envstore-loader.test.js +0 -143
  362. package/dist/src/yaml/steps/fastlane.d.ts +0 -27
  363. package/dist/src/yaml/steps/fastlane.d.ts.map +0 -1
  364. package/dist/src/yaml/steps/fastlane.js +0 -79
  365. package/dist/src/yaml/steps/fidelity-aspect-guard.d.ts +0 -53
  366. package/dist/src/yaml/steps/fidelity-aspect-guard.d.ts.map +0 -1
  367. package/dist/src/yaml/steps/fidelity-aspect-guard.js +0 -72
  368. package/dist/src/yaml/steps/fidelity-aspect-guard.test.d.ts +0 -11
  369. package/dist/src/yaml/steps/fidelity-aspect-guard.test.d.ts.map +0 -1
  370. package/dist/src/yaml/steps/fidelity-aspect-guard.test.js +0 -50
  371. package/dist/src/yaml/steps/fidelity-reference-provenance.d.ts +0 -87
  372. package/dist/src/yaml/steps/fidelity-reference-provenance.d.ts.map +0 -1
  373. package/dist/src/yaml/steps/fidelity-reference-provenance.js +0 -111
  374. package/dist/src/yaml/steps/fidelity-reference-provenance.test.d.ts +0 -22
  375. package/dist/src/yaml/steps/fidelity-reference-provenance.test.d.ts.map +0 -1
  376. package/dist/src/yaml/steps/fidelity-reference-provenance.test.js +0 -118
  377. package/dist/src/yaml/steps/file.d.ts +0 -52
  378. package/dist/src/yaml/steps/file.d.ts.map +0 -1
  379. package/dist/src/yaml/steps/file.js +0 -108
  380. package/dist/src/yaml/steps/flutter.d.ts +0 -63
  381. package/dist/src/yaml/steps/flutter.d.ts.map +0 -1
  382. package/dist/src/yaml/steps/flutter.js +0 -215
  383. package/dist/src/yaml/steps/git-clone-names-the-inputs-it-ignores.test.d.ts +0 -16
  384. package/dist/src/yaml/steps/git-clone-names-the-inputs-it-ignores.test.d.ts.map +0 -1
  385. package/dist/src/yaml/steps/git-clone-names-the-inputs-it-ignores.test.js +0 -127
  386. package/dist/src/yaml/steps/git-clone.d.ts +0 -32
  387. package/dist/src/yaml/steps/git-clone.d.ts.map +0 -1
  388. package/dist/src/yaml/steps/git-clone.js +0 -171
  389. package/dist/src/yaml/steps/git-fetch-retry-exec.test.d.ts +0 -10
  390. package/dist/src/yaml/steps/git-fetch-retry-exec.test.d.ts.map +0 -1
  391. package/dist/src/yaml/steps/git-fetch-retry-exec.test.js +0 -162
  392. package/dist/src/yaml/steps/git-fetch-retry.d.ts +0 -62
  393. package/dist/src/yaml/steps/git-fetch-retry.d.ts.map +0 -1
  394. package/dist/src/yaml/steps/git-fetch-retry.js +0 -155
  395. package/dist/src/yaml/steps/git-fetch-retry.test.d.ts +0 -5
  396. package/dist/src/yaml/steps/git-fetch-retry.test.d.ts.map +0 -1
  397. package/dist/src/yaml/steps/git-fetch-retry.test.js +0 -86
  398. package/dist/src/yaml/steps/google-play-deploy.d.ts +0 -37
  399. package/dist/src/yaml/steps/google-play-deploy.d.ts.map +0 -1
  400. package/dist/src/yaml/steps/google-play-deploy.js +0 -193
  401. package/dist/src/yaml/steps/google-play-deploy.test.d.ts +0 -5
  402. package/dist/src/yaml/steps/google-play-deploy.test.d.ts.map +0 -1
  403. package/dist/src/yaml/steps/google-play-deploy.test.js +0 -310
  404. package/dist/src/yaml/steps/gradle-memory.d.ts +0 -61
  405. package/dist/src/yaml/steps/gradle-memory.d.ts.map +0 -1
  406. package/dist/src/yaml/steps/gradle-memory.js +0 -386
  407. package/dist/src/yaml/steps/gradle-memory.test.d.ts +0 -2
  408. package/dist/src/yaml/steps/gradle-memory.test.d.ts.map +0 -1
  409. package/dist/src/yaml/steps/gradle-memory.test.js +0 -344
  410. package/dist/src/yaml/steps/gradle-sdk-cmake.d.ts +0 -28
  411. package/dist/src/yaml/steps/gradle-sdk-cmake.d.ts.map +0 -1
  412. package/dist/src/yaml/steps/gradle-sdk-cmake.js +0 -107
  413. package/dist/src/yaml/steps/gradle-sdk-cmake.test.d.ts +0 -2
  414. package/dist/src/yaml/steps/gradle-sdk-cmake.test.d.ts.map +0 -1
  415. package/dist/src/yaml/steps/gradle-sdk-cmake.test.js +0 -183
  416. package/dist/src/yaml/steps/index.d.ts +0 -10
  417. package/dist/src/yaml/steps/index.d.ts.map +0 -1
  418. package/dist/src/yaml/steps/index.js +0 -1461
  419. package/dist/src/yaml/steps/ios-deps.d.ts +0 -78
  420. package/dist/src/yaml/steps/ios-deps.d.ts.map +0 -1
  421. package/dist/src/yaml/steps/ios-deps.js +0 -279
  422. package/dist/src/yaml/steps/ios-deps.test.d.ts +0 -5
  423. package/dist/src/yaml/steps/ios-deps.test.d.ts.map +0 -1
  424. package/dist/src/yaml/steps/ios-deps.test.js +0 -90
  425. package/dist/src/yaml/steps/ios-signing.d.ts +0 -31
  426. package/dist/src/yaml/steps/ios-signing.d.ts.map +0 -1
  427. package/dist/src/yaml/steps/ios-signing.js +0 -144
  428. package/dist/src/yaml/steps/ios-version.d.ts +0 -47
  429. package/dist/src/yaml/steps/ios-version.d.ts.map +0 -1
  430. package/dist/src/yaml/steps/ios-version.js +0 -151
  431. package/dist/src/yaml/steps/java-home-version-spec.test.d.ts +0 -10
  432. package/dist/src/yaml/steps/java-home-version-spec.test.d.ts.map +0 -1
  433. package/dist/src/yaml/steps/java-home-version-spec.test.js +0 -58
  434. package/dist/src/yaml/steps/linting.d.ts +0 -47
  435. package/dist/src/yaml/steps/linting.d.ts.map +0 -1
  436. package/dist/src/yaml/steps/linting.js +0 -148
  437. package/dist/src/yaml/steps/phase2.test.d.ts +0 -6
  438. package/dist/src/yaml/steps/phase2.test.d.ts.map +0 -1
  439. package/dist/src/yaml/steps/phase2.test.js +0 -197
  440. package/dist/src/yaml/steps/phase3.test.d.ts +0 -5
  441. package/dist/src/yaml/steps/phase3.test.d.ts.map +0 -1
  442. package/dist/src/yaml/steps/phase3.test.js +0 -144
  443. package/dist/src/yaml/steps/phase4.test.d.ts +0 -5
  444. package/dist/src/yaml/steps/phase4.test.d.ts.map +0 -1
  445. package/dist/src/yaml/steps/phase4.test.js +0 -166
  446. package/dist/src/yaml/steps/phase5.test.d.ts +0 -6
  447. package/dist/src/yaml/steps/phase5.test.d.ts.map +0 -1
  448. package/dist/src/yaml/steps/phase5.test.js +0 -263
  449. package/dist/src/yaml/steps/registry.d.ts +0 -88
  450. package/dist/src/yaml/steps/registry.d.ts.map +0 -1
  451. package/dist/src/yaml/steps/registry.js +0 -125
  452. package/dist/src/yaml/steps/registry.test.d.ts +0 -5
  453. package/dist/src/yaml/steps/registry.test.d.ts.map +0 -1
  454. package/dist/src/yaml/steps/registry.test.js +0 -235
  455. package/dist/src/yaml/steps/release.d.ts +0 -50
  456. package/dist/src/yaml/steps/release.d.ts.map +0 -1
  457. package/dist/src/yaml/steps/release.js +0 -154
  458. package/dist/src/yaml/steps/render-post-processor.d.ts +0 -100
  459. package/dist/src/yaml/steps/render-post-processor.d.ts.map +0 -1
  460. package/dist/src/yaml/steps/render-post-processor.js +0 -270
  461. package/dist/src/yaml/steps/render-post-processor.test.d.ts +0 -13
  462. package/dist/src/yaml/steps/render-post-processor.test.d.ts.map +0 -1
  463. package/dist/src/yaml/steps/render-post-processor.test.js +0 -220
  464. package/dist/src/yaml/steps/script.d.ts +0 -23
  465. package/dist/src/yaml/steps/script.d.ts.map +0 -1
  466. package/dist/src/yaml/steps/script.js +0 -63
  467. package/dist/src/yaml/steps/spec-validation.test.d.ts +0 -6
  468. package/dist/src/yaml/steps/spec-validation.test.d.ts.map +0 -1
  469. package/dist/src/yaml/steps/spec-validation.test.js +0 -130
  470. package/dist/src/yaml/steps/steps.test.d.ts +0 -6
  471. package/dist/src/yaml/steps/steps.test.d.ts.map +0 -1
  472. package/dist/src/yaml/steps/steps.test.js +0 -881
  473. package/dist/src/yaml/steps/structural-facts.d.ts +0 -992
  474. package/dist/src/yaml/steps/structural-facts.d.ts.map +0 -1
  475. package/dist/src/yaml/steps/structural-facts.js +0 -3276
  476. package/dist/src/yaml/steps/structural-facts.test.d.ts +0 -12
  477. package/dist/src/yaml/steps/structural-facts.test.d.ts.map +0 -1
  478. package/dist/src/yaml/steps/structural-facts.test.js +0 -3039
  479. package/dist/src/yaml/steps/test-config.d.ts +0 -5
  480. package/dist/src/yaml/steps/test-config.d.ts.map +0 -1
  481. package/dist/src/yaml/steps/test-config.js +0 -25
  482. package/dist/src/yaml/steps/trim-align-corpus.test.d.ts +0 -28
  483. package/dist/src/yaml/steps/trim-align-corpus.test.d.ts.map +0 -1
  484. package/dist/src/yaml/steps/trim-align-corpus.test.js +0 -383
  485. package/dist/src/yaml/steps/trim-align.d.ts +0 -87
  486. package/dist/src/yaml/steps/trim-align.d.ts.map +0 -1
  487. package/dist/src/yaml/steps/trim-align.js +0 -367
  488. package/dist/src/yaml/steps/trim-align.test.d.ts +0 -11
  489. package/dist/src/yaml/steps/trim-align.test.d.ts.map +0 -1
  490. package/dist/src/yaml/steps/trim-align.test.js +0 -261
  491. package/dist/src/yaml/steps/ui-fidelity-preview-android.d.ts +0 -66
  492. package/dist/src/yaml/steps/ui-fidelity-preview-android.d.ts.map +0 -1
  493. package/dist/src/yaml/steps/ui-fidelity-preview-android.js +0 -251
  494. package/dist/src/yaml/steps/ui-fidelity-preview-android.test.d.ts +0 -13
  495. package/dist/src/yaml/steps/ui-fidelity-preview-android.test.d.ts.map +0 -1
  496. package/dist/src/yaml/steps/ui-fidelity-preview-android.test.js +0 -302
  497. package/dist/src/yaml/steps/ui-fidelity-preview.d.ts +0 -134
  498. package/dist/src/yaml/steps/ui-fidelity-preview.d.ts.map +0 -1
  499. package/dist/src/yaml/steps/ui-fidelity-preview.js +0 -173
  500. package/dist/src/yaml/steps/ui-fidelity-preview.test.d.ts +0 -11
  501. package/dist/src/yaml/steps/ui-fidelity-preview.test.d.ts.map +0 -1
  502. package/dist/src/yaml/steps/ui-fidelity-preview.test.js +0 -210
  503. package/dist/src/yaml/steps/ui-fidelity-render-android.d.ts +0 -155
  504. package/dist/src/yaml/steps/ui-fidelity-render-android.d.ts.map +0 -1
  505. package/dist/src/yaml/steps/ui-fidelity-render-android.js +0 -1389
  506. package/dist/src/yaml/steps/ui-fidelity-render-android.test.d.ts +0 -2
  507. package/dist/src/yaml/steps/ui-fidelity-render-android.test.d.ts.map +0 -1
  508. package/dist/src/yaml/steps/ui-fidelity-render-android.test.js +0 -1106
  509. package/dist/src/yaml/steps/ui-fidelity-render.d.ts +0 -230
  510. package/dist/src/yaml/steps/ui-fidelity-render.d.ts.map +0 -1
  511. package/dist/src/yaml/steps/ui-fidelity-render.js +0 -1597
  512. package/dist/src/yaml/steps/ui-fidelity-render.test.d.ts +0 -18
  513. package/dist/src/yaml/steps/ui-fidelity-render.test.d.ts.map +0 -1
  514. package/dist/src/yaml/steps/ui-fidelity-render.test.js +0 -1871
  515. package/dist/src/yaml/steps/xcode-app-product.d.ts +0 -90
  516. package/dist/src/yaml/steps/xcode-app-product.d.ts.map +0 -1
  517. package/dist/src/yaml/steps/xcode-app-product.js +0 -247
  518. package/dist/src/yaml/steps/xcode-app-product.test.d.ts +0 -2
  519. package/dist/src/yaml/steps/xcode-app-product.test.d.ts.map +0 -1
  520. package/dist/src/yaml/steps/xcode-app-product.test.js +0 -202
  521. package/dist/src/yaml/steps/xcode-derived-data.test.d.ts +0 -30
  522. package/dist/src/yaml/steps/xcode-derived-data.test.d.ts.map +0 -1
  523. package/dist/src/yaml/steps/xcode-derived-data.test.js +0 -279
  524. package/dist/src/yaml/steps/xcode-destination.d.ts +0 -47
  525. package/dist/src/yaml/steps/xcode-destination.d.ts.map +0 -1
  526. package/dist/src/yaml/steps/xcode-destination.js +0 -202
  527. package/dist/src/yaml/steps/xcode-destination.test.d.ts +0 -9
  528. package/dist/src/yaml/steps/xcode-destination.test.d.ts.map +0 -1
  529. package/dist/src/yaml/steps/xcode-destination.test.js +0 -227
  530. package/dist/src/yaml/steps/xcode-new.test.d.ts +0 -5
  531. package/dist/src/yaml/steps/xcode-new.test.d.ts.map +0 -1
  532. package/dist/src/yaml/steps/xcode-new.test.js +0 -211
  533. package/dist/src/yaml/steps/xcode-resolve-retry.test.d.ts +0 -9
  534. package/dist/src/yaml/steps/xcode-resolve-retry.test.d.ts.map +0 -1
  535. package/dist/src/yaml/steps/xcode-resolve-retry.test.js +0 -146
  536. package/dist/src/yaml/steps/xcode-simulator-archs.d.ts +0 -53
  537. package/dist/src/yaml/steps/xcode-simulator-archs.d.ts.map +0 -1
  538. package/dist/src/yaml/steps/xcode-simulator-archs.js +0 -98
  539. package/dist/src/yaml/steps/xcode-simulator-archs.test.d.ts +0 -21
  540. package/dist/src/yaml/steps/xcode-simulator-archs.test.d.ts.map +0 -1
  541. package/dist/src/yaml/steps/xcode-simulator-archs.test.js +0 -155
  542. package/dist/src/yaml/steps/xcode.d.ts +0 -230
  543. package/dist/src/yaml/steps/xcode.d.ts.map +0 -1
  544. package/dist/src/yaml/steps/xcode.js +0 -1350
  545. package/dist/src/yaml/types.d.ts +0 -76
  546. package/dist/src/yaml/types.d.ts.map +0 -1
  547. package/dist/src/yaml/types.js +0 -5
  548. package/dist/src/yaml/validation-types.d.ts +0 -102
  549. package/dist/src/yaml/validation-types.d.ts.map +0 -1
  550. package/dist/src/yaml/validation-types.js +0 -8
  551. package/dist/src/yaml/yaml-updater.d.ts +0 -24
  552. package/dist/src/yaml/yaml-updater.d.ts.map +0 -1
  553. package/dist/src/yaml/yaml-updater.js +0 -128
@@ -1,270 +0,0 @@
1
- /**
2
- * Shared render-output post-processor.
3
- *
4
- * The single source of truth for turning a freshly rendered PNG into the
5
- * artifacts the fidelity loop compares: a content-trimmed image, a
6
- * reference-sized aligned copy, and the reported dimensions (rendered px /
7
- * logical pt / reference px). It operates on PNGs regardless of how they were
8
- * produced -- a SwiftUI `ImageRenderer` render or a Compose/Roborazzi render --
9
- * so crop/align/dimension behavior cannot drift between platforms.
10
- *
11
- * The pixel work is the pure-JS trim/align helper in trim-align.ts, invoked
12
- * through the ci binary (`ci fidelity-trim`) -- the one artifact present on
13
- * every backend -- so iOS and Android run the SAME bytes on macOS and Linux
14
- * alike. It replaced an embedded CoreGraphics/ImageIO helper that ran via
15
- * `swift` in script-interpreter mode and therefore could not run on Linux
16
- * workers (fidelity-linux 06); the bounding-box, fit-pad, and TRIMDIMS
17
- * semantics are a faithful port of that helper, guarded by a pixel-identity
18
- * corpus gate (trim-align-corpus.test.ts).
19
- *
20
- * This module is consumed by `ui-fidelity-render.ts` (iOS) and
21
- * `ui-fidelity-render-android.ts`; the surrounding JS orchestration is spliced
22
- * into each platform's generated runtime script.
23
- */
24
- import { existsSync } from 'node:fs';
25
- import { dirname, join } from 'node:path';
26
- import { fileURLToPath } from 'node:url';
27
- /**
28
- * Runtime support for trimming the rendered output (package_source variants).
29
- *
30
- * The render entry forces the view into a fixed device-sized frame, so a
31
- * component smaller than the canvas renders with transparent margins. After a
32
- * screen renders, crop the PNG in place to the bounding box of its
33
- * non-transparent pixels, so the rendered artifact is the component itself,
34
- * tight -- no canvas, no background ambiguity for the human comparing screens.
35
- *
36
- * Best-effort: a trim failure is logged (warn-and-continue) and the untrimmed
37
- * render is kept -- a cosmetic post-step never fails an otherwise good render.
38
- * This is prep, not scoring: it produces a tighter image for the human's
39
- * judgment and computes nothing about fidelity.
40
- *
41
- * NOTE: the comments inside the stage string ship inside generated runtime
42
- * scripts. Keep them free of platform-toolchain references -- there is a unit
43
- * gate asserting the stage never mentions the old interpreter.
44
- */
45
- export const RENDER_SCRIPT_TRIM_STAGE = '\n// ---- render trimming stage (package_source variants) ----\n' +
46
- String.raw `
47
- // Round to two decimals, keeping the value a plain number.
48
- function roundTwo(value) {
49
- return Math.round(value * 100) / 100;
50
- }
51
-
52
- // Parse the helper's "TRIMDIMS <rW> <rH> <refW> <refH> <srcW> <srcH>
53
- // [<offX> <offY>]" line (rendered/reference/source px + the crop origin;
54
- // last one wins). The origin is null on a 6-number line — an old helper may
55
- // well have trimmed something, so an absent origin means UNKNOWN, never zero.
56
- function parseTrimDims(stdout) {
57
- var lines = String(stdout || '').split('\n');
58
- for (var i = lines.length - 1; i >= 0; i--) {
59
- var parts = lines[i].trim().split(/\s+/);
60
- if (parts[0] === 'TRIMDIMS' && parts.length >= 7) {
61
- var nums = [
62
- Number(parts[1]), Number(parts[2]), Number(parts[3]),
63
- Number(parts[4]), Number(parts[5]), Number(parts[6]),
64
- ];
65
- if (nums.every(function (n) { return Number.isFinite(n); })) {
66
- var offset = null;
67
- if (parts.length >= 9) {
68
- var offX = Number(parts[7]);
69
- var offY = Number(parts[8]);
70
- if (Number.isFinite(offX) && Number.isFinite(offY)) {
71
- offset = [offX, offY];
72
- }
73
- }
74
- return {
75
- rendered: [nums[0], nums[1]],
76
- reference: [nums[2], nums[3]],
77
- source: [nums[4], nums[5]],
78
- offset: offset,
79
- };
80
- }
81
- }
82
- }
83
- return null;
84
- }
85
-
86
- // Lazily copy the pkg ci binary to a scratch path so the trim can invoke it
87
- // WITHOUT re-executing process.execPath. Under pkg the generated render script
88
- // runs as an app-mode child of the ci binary, so process.execPath IS the ci
89
- // binary -- but pkg refuses to let a binary re-invoke ITSELF as a subcommand:
90
- // spawning process.execPath forces the child into Node-emulation, where
91
- // 'fidelity-trim' is treated as a main-module script path ("Cannot find module
92
- // '<cwd>/fidelity-trim'") and the subcommand dispatch never runs, so the trim
93
- // silently no-ops and untrimmed renders ship. A COPY of the binary at a
94
- // different path is NOT seen as a self-exec, so it runs the baked cli entrypoint
95
- // normally (with the bundled pngjs). Copied once per run; returns null if the
96
- // copy can't be made, and the caller then degrades to a best-effort no-op trim.
97
- // Verified on the runner: a copy-spawn dispatches and emits TRIMDIMS, while an
98
- // execPath self-exec crashes with the module-not-found above.
99
- var ciTrimBinCopy;
100
- function ciBinaryCopyForTrim() {
101
- if (typeof ciTrimBinCopy !== 'undefined') return ciTrimBinCopy;
102
- try {
103
- var dest = path.join(os.tmpdir(), 'ci-fidelity-trim-bin');
104
- if (!fs.existsSync(dest)) {
105
- fs.copyFileSync(process.execPath, dest);
106
- fs.chmodSync(dest, 493); // 0o755
107
- }
108
- ciTrimBinCopy = dest;
109
- } catch (copyErr) {
110
- ciTrimBinCopy = null;
111
- }
112
- return ciTrimBinCopy;
113
- }
114
-
115
- // Resolve how to reach the ci CLI's fidelity-trim helper from inside this
116
- // generated script. Three homes, in order:
117
- // 1. CIBUILD_CLI_JS -- an explicit JS entrypoint (preview harnesses, tests),
118
- // run under the same node executing this script.
119
- // 2. Under pkg (the production runner path) process.execPath IS the ci binary,
120
- // but pkg won't let it re-invoke itself as a subcommand, so spawn a COPY of
121
- // it (see ciBinaryCopyForTrim). Fall back to the (best-effort) self-exec if
122
- // the copy can't be made.
123
- // 3. A ci on PATH (brew/npm installs) when not running under pkg.
124
- function trimHelperInvocation(args) {
125
- if (process.env.CIBUILD_CLI_JS) {
126
- return {
127
- cmd: process.execPath,
128
- args: [process.env.CIBUILD_CLI_JS, 'fidelity-trim'].concat(args),
129
- };
130
- }
131
- if (process.pkg) {
132
- var copy = ciBinaryCopyForTrim();
133
- return {
134
- cmd: copy === null ? process.execPath : copy,
135
- args: ['fidelity-trim'].concat(args),
136
- };
137
- }
138
- return { cmd: 'ci', args: ['fidelity-trim'].concat(args) };
139
- }
140
-
141
- // Run the trim/align helper (pure JS inside the ci binary; the argv, TRIMDIMS
142
- // stdout line, and exit codes are the retired CoreGraphics helper's contract).
143
- function runTrimHelper(args) {
144
- var invocation = trimHelperInvocation(args);
145
- // Strip pkg's node-invoke sentinel (PKG_EXECPATH) from the child env as a
146
- // belt-and-suspenders alongside the copy-binary indirection above, so the
147
- // spawned ci runs its baked cli entrypoint and dispatches the subcommand.
148
- var childEnv = Object.assign({}, process.env);
149
- delete childEnv.PKG_EXECPATH;
150
- var result = cp.spawnSync(invocation.cmd, invocation.args, {
151
- encoding: 'utf-8',
152
- maxBuffer: 16 * 1024 * 1024,
153
- env: childEnv,
154
- });
155
- if (result.stdout) process.stdout.write(result.stdout);
156
- if (result.stderr) process.stderr.write(result.stderr);
157
- if (result.error) {
158
- result.status = result.status == null ? 127 : result.status;
159
- result.stderr = (result.stderr || '') + String(result.error.message || result.error);
160
- }
161
- return result;
162
- }
163
-
164
- // Crop the rendered PNG in place to its content bounding box, write an aligned
165
- // copy resized to the reference, and record the dimensions on the entry.
166
- // Best-effort: a failure is logged and the untrimmed render is kept.
167
- function trimRenderedImage(entry, renderedPath) {
168
- var alignedRelative = 'ui-fidelity/aligned/' + entry.screen + '.png';
169
- var alignedPath = path.resolve(artifactsDir, alignedRelative);
170
- var referencePath =
171
- entry.reference_image_path === null
172
- ? ''
173
- : path.resolve(artifactsDir, entry.reference_image_path);
174
- try {
175
- fs.mkdirSync(path.dirname(alignedPath), { recursive: true });
176
- } catch (mkdirError) {
177
- // best effort -- the helper reports a missing output dir itself
178
- }
179
- var result = runTrimHelper([renderedPath, renderedPath, alignedPath, referencePath]);
180
- if (result.status !== 0) {
181
- logError(
182
- 'trim failed for ' + renderedPath +
183
- ' (continuing with the untrimmed render): ' + sanitizeMessage(outputTail(result))
184
- );
185
- return;
186
- }
187
- var dims = parseTrimDims(result.stdout);
188
- if (dims !== null) {
189
- var scale = CONFIG.scale;
190
- entry.dimensions = {
191
- rendered_px: dims.rendered,
192
- logical_pt: [roundTwo(dims.rendered[0] / scale), roundTwo(dims.rendered[1] / scale)],
193
- reference_px: dims.reference[0] > 0 && dims.reference[1] > 0 ? dims.reference : null,
194
- // The PRE-TRIM raster: what the renderer actually PAINTED, before cropping
195
- // to content. The gate's frame-fill check needs it to tell "the wrapper
196
- // never reached its design frame" (a real defect) from "the wrapper filled
197
- // the frame in a UNIFORM colour, so the trim cropped its own padding back
198
- // off" (not a defect -- and previously indistinguishable, which meant a
199
- // padding fix could never close its finding: post-trim px are identical
200
- // before and after the fix).
201
- source_px: dims.source,
202
- };
203
- // The crop origin, when the helper reported one: where the trimmed image
204
- // sits inside the source raster. The dashboard subtracts it to place the
205
- // layout dump's window-space geometry on the trimmed bytes; omitted (not
206
- // null) when unknown, so a pre-offset helper's dimensions keep their old
207
- // shape exactly.
208
- if (dims.offset !== null) {
209
- entry.dimensions.trim_offset_px = dims.offset;
210
- }
211
- // Surface how much margin was removed -- a no-op (source == rendered) means
212
- // the view fills an opaque canvas with no transparent or uniform margin.
213
- log(
214
- 'trimmed ' + entry.screen + ': ' + dims.source[0] + 'x' + dims.source[1] +
215
- ' -> ' + dims.rendered[0] + 'x' + dims.rendered[1]
216
- );
217
- }
218
- if (fs.existsSync(alignedPath)) {
219
- entry.aligned_image_path = alignedRelative;
220
- }
221
- }
222
- `;
223
- /**
224
- * Evaluates the embedded trim-stage source and returns its pure helpers, so
225
- * unit tests exercise exactly the code that ships inside the runtime script
226
- * (mirrors getRenderScriptInternals in ui-fidelity-render.ts). `cp`, `process`,
227
- * `fs`, `os` and `path` are injectable so the invocation/spawn/copy seams are
228
- * testable; at runtime the stage is spliced into the generated script where
229
- * those names are `require`d globals. Uninjected deps only matter for branches
230
- * that dereference them (the pkg copy path), so existing callers can omit them.
231
- */
232
- export function getPostProcessorInternals(overrides) {
233
- const factory = new Function('cp', 'process', 'fs', 'os', 'path', RENDER_SCRIPT_TRIM_STAGE +
234
- '\nreturn { parseTrimDims: parseTrimDims, roundTwo: roundTwo, ' +
235
- 'trimHelperInvocation: trimHelperInvocation, runTrimHelper: runTrimHelper };');
236
- return factory(overrides?.cp, overrides?.processRef ?? process, overrides?.fs, overrides?.os, overrides?.path);
237
- }
238
- /**
239
- * Resolves the on-disk JS entrypoint of this cibuild installation's CLI
240
- * (dist/cli.cjs), for callers that spawn a generated render script directly
241
- * (the preview harnesses) and must hand it a working CIBUILD_CLI_JS. Returns
242
- * null when no built CLI exists nearby (e.g. running from src under jest) --
243
- * the script then falls back to `ci` on PATH.
244
- */
245
- export function resolveCliJsPath() {
246
- let moduleDir;
247
- try {
248
- moduleDir = dirname(fileURLToPath(import.meta.url));
249
- }
250
- catch {
251
- return null;
252
- }
253
- const candidates = [
254
- // Bundled: import.meta.url is shimmed to dist/cli.cjs itself.
255
- join(moduleDir, 'cli.cjs'),
256
- // Compiled layout: dist/src/yaml/steps/*.js -> dist/cli.cjs.
257
- join(moduleDir, '..', '..', '..', 'cli.cjs'),
258
- ];
259
- for (const candidate of candidates) {
260
- try {
261
- if (existsSync(candidate))
262
- return candidate;
263
- }
264
- catch {
265
- // keep looking
266
- }
267
- }
268
- return null;
269
- }
270
- //# sourceMappingURL=render-post-processor.js.map
@@ -1,13 +0,0 @@
1
- /**
2
- * Direct tests for the shared render-output post-processor.
3
- *
4
- * The dimension-reporting logic (TRIMDIMS parsing, the logical-pt rounding
5
- * primitive) and the helper-invocation resolution are pure JS embedded in the
6
- * trim-stage script. They are evaluated out of the shipped string via
7
- * getPostProcessorInternals() and tested directly, so these run in every CI
8
- * pass. The pixel logic itself lives in trim-align.ts (tested ungated in
9
- * trim-align.test.ts); the Swift-vs-JS equivalence is guarded by the corpus
10
- * gate in trim-align-corpus.test.ts.
11
- */
12
- export {};
13
- //# sourceMappingURL=render-post-processor.test.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"render-post-processor.test.d.ts","sourceRoot":"","sources":["../../../../src/yaml/steps/render-post-processor.test.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG"}
@@ -1,220 +0,0 @@
1
- /**
2
- * Direct tests for the shared render-output post-processor.
3
- *
4
- * The dimension-reporting logic (TRIMDIMS parsing, the logical-pt rounding
5
- * primitive) and the helper-invocation resolution are pure JS embedded in the
6
- * trim-stage script. They are evaluated out of the shipped string via
7
- * getPostProcessorInternals() and tested directly, so these run in every CI
8
- * pass. The pixel logic itself lives in trim-align.ts (tested ungated in
9
- * trim-align.test.ts); the Swift-vs-JS equivalence is guarded by the corpus
10
- * gate in trim-align-corpus.test.ts.
11
- */
12
- import { getPostProcessorInternals, RENDER_SCRIPT_TRIM_STAGE, } from './render-post-processor.js';
13
- describe('dimension reporting (TRIMDIMS parsing)', () => {
14
- const { parseTrimDims } = getPostProcessorInternals();
15
- test('parses a well-formed TRIMDIMS line into rendered/reference/source px', () => {
16
- const dims = parseTrimDims('TRIMDIMS 320 640 160 320 400 800\n');
17
- expect(dims).toEqual({
18
- rendered: [320, 640],
19
- reference: [160, 320],
20
- source: [400, 800],
21
- // A 6-number line is the pre-offset helper — the origin is unknown, not
22
- // zero: an old binary may well have trimmed something.
23
- offset: null,
24
- });
25
- });
26
- test('parses the crop origin from an 8-number TRIMDIMS line', () => {
27
- const dims = parseTrimDims('TRIMDIMS 320 640 160 320 400 800 40 77\n');
28
- expect(dims).toEqual({
29
- rendered: [320, 640],
30
- reference: [160, 320],
31
- source: [400, 800],
32
- offset: [40, 77],
33
- });
34
- });
35
- test('a non-numeric origin degrades to offset null, never to garbage', () => {
36
- const dims = parseTrimDims('TRIMDIMS 320 640 160 320 400 800 x y\n');
37
- expect(dims?.offset).toBeNull();
38
- expect(dims?.rendered).toEqual([320, 640]);
39
- });
40
- test('returns null when no TRIMDIMS line is present', () => {
41
- expect(parseTrimDims('rendered HomeView\nsome other log line\n')).toBeNull();
42
- expect(parseTrimDims('')).toBeNull();
43
- });
44
- test('takes the last TRIMDIMS line and ignores surrounding log noise', () => {
45
- const stdout = [
46
- 'TRIMDIMS 10 10 10 10 10 10',
47
- 'helper: warming up',
48
- 'TRIMDIMS 320 640 160 320 400 800',
49
- 'helper: done',
50
- ].join('\n');
51
- expect(parseTrimDims(stdout)).toEqual({
52
- rendered: [320, 640],
53
- reference: [160, 320],
54
- source: [400, 800],
55
- offset: null,
56
- });
57
- });
58
- test('returns null for a truncated or non-numeric TRIMDIMS line', () => {
59
- expect(parseTrimDims('TRIMDIMS 320 640 160 320\n')).toBeNull();
60
- expect(parseTrimDims('TRIMDIMS 320 x 160 320 400 800\n')).toBeNull();
61
- });
62
- test('reports a zero reference pair when no reference was available', () => {
63
- // The helper prints "0 0" for the reference when it cannot load one; the
64
- // render step maps that to a null reference_px when reporting dimensions.
65
- const dims = parseTrimDims('TRIMDIMS 320 640 0 0 400 800\n');
66
- expect(dims?.reference).toEqual([0, 0]);
67
- });
68
- });
69
- describe('logical-pt rounding (roundTwo)', () => {
70
- const { roundTwo } = getPostProcessorInternals();
71
- test('rounds a logical-point value to two decimals', () => {
72
- expect(roundTwo(360 / 2)).toBe(180);
73
- expect(roundTwo(343 / 2)).toBe(171.5);
74
- expect(roundTwo(100 / 3)).toBe(33.33);
75
- });
76
- });
77
- // The generated scripts run under whatever node executes the step (a system
78
- // node, the pkg-built ci binary's bootstrap, or a preview harness), so the
79
- // stage must resolve how to reach the ci CLI's fidelity-trim helper at run
80
- // time. The resolution order is load-bearing: an explicit CIBUILD_CLI_JS
81
- // (preview harnesses, tests) wins, then the pkg self-exec (the production
82
- // runner path), then a `ci` on PATH.
83
- describe('trim stage — helper invocation resolution', () => {
84
- function internalsWith(processRef) {
85
- return getPostProcessorInternals({ processRef });
86
- }
87
- test('an explicit CIBUILD_CLI_JS entrypoint wins and runs under this node', () => {
88
- const { trimHelperInvocation } = internalsWith({
89
- env: { CIBUILD_CLI_JS: '/opt/cibuild/cli.cjs' },
90
- execPath: '/usr/local/bin/node',
91
- });
92
- expect(trimHelperInvocation(['in.png', 'out.png'])).toEqual({
93
- cmd: '/usr/local/bin/node',
94
- args: ['/opt/cibuild/cli.cjs', 'fidelity-trim', 'in.png', 'out.png'],
95
- });
96
- });
97
- // Under pkg (the production runner path — process.pkg IS set, verified on the
98
- // runner), process.execPath IS the ci binary, and pkg REFUSES to let a binary
99
- // re-invoke itself as a subcommand: spawning process.execPath forces the child
100
- // into Node-emulation, where 'fidelity-trim' becomes a main-module script path
101
- // ("Cannot find module '<cwd>/fidelity-trim'") and the dispatch never runs —
102
- // the trim silently no-ops and untrimmed renders ship. A COPY of the binary at
103
- // a different path is not a self-exec, so it runs the baked cli entrypoint.
104
- // (Verified on the runner: copy-spawn dispatches + emits TRIMDIMS.)
105
- function pkgInternals(opts) {
106
- const copyCalls = [];
107
- const fakeFs = {
108
- existsSync: () => false,
109
- copyFileSync: (src, dest) => {
110
- copyCalls.push([src, dest]);
111
- if (opts?.copyThrows)
112
- throw new Error('EACCES');
113
- },
114
- chmodSync: () => { },
115
- };
116
- const fakeOs = { tmpdir: () => '/scratch' };
117
- const fakePath = { join: (...parts) => parts.join('/') };
118
- const internals = getPostProcessorInternals({
119
- processRef: { env: {}, pkg: {}, execPath: '/opt/homebrew/bin/ci' },
120
- fs: fakeFs,
121
- os: fakeOs,
122
- path: fakePath,
123
- });
124
- return { internals, copyCalls };
125
- }
126
- test('under pkg it spawns a COPY of the binary (not process.execPath)', () => {
127
- const { internals, copyCalls } = pkgInternals();
128
- expect(internals.trimHelperInvocation(['in.png', 'out.png', 'aligned.png', 'ref.png'])).toEqual({
129
- cmd: '/scratch/ci-fidelity-trim-bin',
130
- args: ['fidelity-trim', 'in.png', 'out.png', 'aligned.png', 'ref.png'],
131
- });
132
- // The copy is made once, from process.execPath.
133
- expect(copyCalls).toEqual([['/opt/homebrew/bin/ci', '/scratch/ci-fidelity-trim-bin']]);
134
- });
135
- test('under pkg it degrades to process.execPath when the binary copy fails', () => {
136
- const { internals } = pkgInternals({ copyThrows: true });
137
- expect(internals.trimHelperInvocation(['in.png', 'out.png'])).toEqual({
138
- cmd: '/opt/homebrew/bin/ci',
139
- args: ['fidelity-trim', 'in.png', 'out.png'],
140
- });
141
- });
142
- test('falls back to a ci on PATH when not running under pkg', () => {
143
- const { trimHelperInvocation } = internalsWith({
144
- env: {},
145
- execPath: '/usr/local/bin/node',
146
- });
147
- expect(trimHelperInvocation(['in.png', 'out.png'])).toEqual({
148
- cmd: 'ci',
149
- args: ['fidelity-trim', 'in.png', 'out.png'],
150
- });
151
- });
152
- // runTrimHelper strips pkg's node-invoke sentinel (PKG_EXECPATH) from the child
153
- // env as belt-and-suspenders alongside the copy-binary indirection, so the
154
- // spawned ci runs its baked cli entrypoint rather than re-entering
155
- // Node-emulation. (Exercised here via the non-pkg `ci` home for a simple seam.)
156
- test('runTrimHelper strips PKG_EXECPATH from the child env', () => {
157
- const calls = [];
158
- const fakeCp = {
159
- spawnSync: (...args) => {
160
- calls.push(args);
161
- return { status: 0, stdout: 'TRIMDIMS 10 10 0 0 10 10\n', stderr: '' };
162
- },
163
- };
164
- const { runTrimHelper } = getPostProcessorInternals({
165
- cp: fakeCp,
166
- processRef: {
167
- // Node-emulation shape: the sentinel is set but process.pkg is NOT.
168
- env: { PKG_EXECPATH: 'PKG_INVOKE_NODEJS', PATH: '/usr/bin:/bin', FOO: 'bar' },
169
- execPath: '/usr/local/bin/node',
170
- stdout: { write: () => true },
171
- stderr: { write: () => true },
172
- },
173
- });
174
- runTrimHelper(['in.png', 'out.png']);
175
- expect(calls).toHaveLength(1);
176
- const [cmd, , options] = calls[0];
177
- // process.pkg undefined → resolves to `ci` on PATH (the real runner path).
178
- expect(cmd).toBe('ci');
179
- // The child env must have the node-invoke sentinel removed, the rest kept.
180
- expect(options.env).toBeDefined();
181
- expect(options.env?.PKG_EXECPATH).toBeUndefined();
182
- expect(options.env?.PATH).toBe('/usr/bin:/bin');
183
- expect(options.env?.FOO).toBe('bar');
184
- });
185
- test('runTrimHelper reports a spawn error as status 127 with the message appended', () => {
186
- const calls = [];
187
- const fakeCp = {
188
- spawnSync: (...args) => {
189
- calls.push(args);
190
- return { status: null, stdout: '', stderr: '', error: new Error('ENOENT: ci not found') };
191
- },
192
- };
193
- const { runTrimHelper } = getPostProcessorInternals({
194
- cp: fakeCp,
195
- processRef: {
196
- env: {},
197
- execPath: '/usr/local/bin/node',
198
- stdout: { write: () => true },
199
- stderr: { write: () => true },
200
- },
201
- });
202
- const result = runTrimHelper(['in.png', 'out.png']);
203
- expect(result.status).toBe(127);
204
- expect(result.stderr).toContain('ENOENT: ci not found');
205
- expect(calls).toHaveLength(1);
206
- expect(calls[0][0]).toBe('ci');
207
- });
208
- });
209
- // The whole point of the port (fidelity-linux 06): the shipped trim stage must
210
- // not reference the platform toolchain in any form — no helper source, no
211
- // interpreter spawn — so the Android render path can run on Linux workers.
212
- describe('trim stage — no platform-toolchain invocation remains', () => {
213
- test('the stage script has no swift reference at all', () => {
214
- expect(RENDER_SCRIPT_TRIM_STAGE.toLowerCase()).not.toContain('swift');
215
- });
216
- test('the stage spawns the fidelity-trim helper instead', () => {
217
- expect(RENDER_SCRIPT_TRIM_STAGE).toContain("'fidelity-trim'");
218
- });
219
- });
220
- //# sourceMappingURL=render-post-processor.test.js.map
@@ -1,23 +0,0 @@
1
- /**
2
- * Script step implementation
3
- */
4
- import { BaseStepExecutor } from './base.js';
5
- import type { StepDef, CIConfig } from '../../types.js';
6
- import type { ValidationRequirement } from '../validation-types.js';
7
- /**
8
- * Inputs for script step
9
- */
10
- export interface ScriptInputs {
11
- content?: string;
12
- working_dir?: string;
13
- runner_bin?: string;
14
- }
15
- /**
16
- * Script step executor
17
- * Executes arbitrary shell scripts with optional working directory
18
- */
19
- export declare class ScriptStepExecutor extends BaseStepExecutor {
20
- getValidationRequirements(inputs: ScriptInputs, _env: Record<string, string>, _config: CIConfig): ValidationRequirement[];
21
- execute(inputs: ScriptInputs, env: Record<string, string>, config: CIConfig): Promise<StepDef>;
22
- }
23
- //# sourceMappingURL=script.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"script.d.ts","sourceRoot":"","sources":["../../../../src/yaml/steps/script.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,gBAAgB,EAAE,MAAM,WAAW,CAAC;AAC7C,OAAO,KAAK,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AACxD,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,wBAAwB,CAAC;AAEpE;;GAEG;AACH,MAAM,WAAW,YAAY;IAC3B,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AAED;;;GAGG;AACH,qBAAa,kBAAmB,SAAQ,gBAAgB;IACtD,yBAAyB,CACvB,MAAM,EAAE,YAAY,EACpB,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,EAC5B,OAAO,EAAE,QAAQ,GAChB,qBAAqB,EAAE;IAmBpB,OAAO,CAAC,MAAM,EAAE,YAAY,EAAE,GAAG,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,EAAE,MAAM,EAAE,QAAQ,GAAG,OAAO,CAAC,OAAO,CAAC;CAkDrG"}
@@ -1,63 +0,0 @@
1
- /**
2
- * Script step implementation
3
- */
4
- import { BaseStepExecutor } from './base.js';
5
- /**
6
- * Script step executor
7
- * Executes arbitrary shell scripts with optional working directory
8
- */
9
- export class ScriptStepExecutor extends BaseStepExecutor {
10
- getValidationRequirements(inputs, _env, _config) {
11
- const requirements = [];
12
- // content is required
13
- requirements.push(this.requireInput('content', inputs, 'Script content to execute', 'Provide content input with your script'));
14
- // Check runner if non-bash
15
- const runner = this.getInput(inputs, 'runner_bin', 'bash');
16
- if (runner !== 'bash' && !runner.includes('bash')) {
17
- requirements.push(this.requireCommand(runner, `Script runner: ${runner}`, `Install ${runner} or use bash as the runner`));
18
- }
19
- return requirements;
20
- }
21
- async execute(inputs, env, config) {
22
- const stepName = 'script';
23
- // Get script content - this is required
24
- const content = this.getRequiredInput(inputs, 'content', stepName);
25
- // Get working directory - optional, defaults to current directory
26
- const workingDir = this.getInput(inputs, 'working_dir', '');
27
- // Get runner bin - optional, defaults to bash
28
- const runnerBin = this.getInput(inputs, 'runner_bin', 'bash');
29
- const commands = [];
30
- // Change to working directory if specified
31
- if (workingDir && workingDir.trim() !== '') {
32
- commands.push(`# Changing to working directory: ${this.escapeBash(workingDir)}`);
33
- commands.push(`cd '${this.escapeBash(workingDir)}'`);
34
- commands.push('');
35
- }
36
- // Add the user's script content
37
- commands.push('# User script content');
38
- commands.push(content);
39
- const script = this.createBashScriptFromCommands(commands, stepName);
40
- // Determine the kind based on runner_bin
41
- let kind = 'script';
42
- if (runnerBin.includes('python')) {
43
- kind = 'python';
44
- }
45
- else if (runnerBin.includes('ruby')) {
46
- kind = 'ruby';
47
- }
48
- else if (runnerBin.includes('node')) {
49
- kind = 'node';
50
- }
51
- // For non-bash runners, return the content directly
52
- if (kind !== 'script') {
53
- return {
54
- id: '',
55
- name: stepName,
56
- kind,
57
- script: content,
58
- };
59
- }
60
- return this.createScriptStep(script, stepName);
61
- }
62
- }
63
- //# sourceMappingURL=script.js.map
@@ -1,6 +0,0 @@
1
- /**
2
- * Validates that step spec YAML files stay in sync with the step registry
3
- * and that bitrise-map.yml is consistent.
4
- */
5
- export {};
6
- //# sourceMappingURL=spec-validation.test.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"spec-validation.test.d.ts","sourceRoot":"","sources":["../../../../src/yaml/steps/spec-validation.test.ts"],"names":[],"mappings":"AAAA;;;GAGG"}