@convesoft/nx-rust 0.0.0-stage → 1.0.0-rc.1

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 (391) hide show
  1. package/LICENSE-APACHE +201 -0
  2. package/LICENSE-MIT +21 -0
  3. package/README.md +48 -2
  4. package/executors.json +35 -0
  5. package/generators.json +19 -0
  6. package/package.json +26 -4
  7. package/src/cargo/build-settings.d.ts +54 -0
  8. package/src/cargo/build-settings.js +93 -0
  9. package/src/cargo/build-settings.js.map +1 -0
  10. package/src/cargo/configured-runner.d.ts +36 -0
  11. package/src/cargo/configured-runner.js +99 -0
  12. package/src/cargo/configured-runner.js.map +1 -0
  13. package/src/cargo/configured-tools.d.ts +35 -0
  14. package/src/cargo/configured-tools.js +46 -0
  15. package/src/cargo/configured-tools.js.map +1 -0
  16. package/src/cargo/dep-info-basedir.d.ts +18 -0
  17. package/src/cargo/dep-info-basedir.js +38 -0
  18. package/src/cargo/dep-info-basedir.js.map +1 -0
  19. package/src/cargo/directories.d.ts +40 -0
  20. package/src/cargo/directories.js +89 -0
  21. package/src/cargo/directories.js.map +1 -0
  22. package/src/cargo/host-triple.d.ts +7 -0
  23. package/src/cargo/host-triple.js +21 -0
  24. package/src/cargo/host-triple.js.map +1 -0
  25. package/src/cargo/lockfile.d.ts +63 -0
  26. package/src/cargo/lockfile.js +157 -0
  27. package/src/cargo/lockfile.js.map +1 -0
  28. package/src/cargo/metadata.d.ts +112 -0
  29. package/src/cargo/metadata.js +37 -0
  30. package/src/cargo/metadata.js.map +1 -0
  31. package/src/cargo/package-specs.d.ts +54 -0
  32. package/src/cargo/package-specs.js +109 -0
  33. package/src/cargo/package-specs.js.map +1 -0
  34. package/src/cargo/paths-crates.d.ts +27 -0
  35. package/src/cargo/paths-crates.js +69 -0
  36. package/src/cargo/paths-crates.js.map +1 -0
  37. package/src/cargo/print-artifact-folders.d.ts +1 -0
  38. package/src/cargo/print-artifact-folders.js +58 -0
  39. package/src/cargo/print-artifact-folders.js.map +1 -0
  40. package/src/cargo/redirections.d.ts +87 -0
  41. package/src/cargo/redirections.js +195 -0
  42. package/src/cargo/redirections.js.map +1 -0
  43. package/src/cargo/run-cargo.d.ts +31 -0
  44. package/src/cargo/run-cargo.js +75 -0
  45. package/src/cargo/run-cargo.js.map +1 -0
  46. package/src/cargo/target-triples.d.ts +98 -0
  47. package/src/cargo/target-triples.js +265 -0
  48. package/src/cargo/target-triples.js.map +1 -0
  49. package/src/cargo/version-req.d.ts +12 -0
  50. package/src/cargo/version-req.js +122 -0
  51. package/src/cargo/version-req.js.map +1 -0
  52. package/src/compatibility/cargo-version.d.ts +43 -0
  53. package/src/compatibility/cargo-version.js +83 -0
  54. package/src/compatibility/cargo-version.js.map +1 -0
  55. package/src/compatibility/nx-bridge.d.ts +312 -0
  56. package/src/compatibility/nx-bridge.js +407 -0
  57. package/src/compatibility/nx-bridge.js.map +1 -0
  58. package/src/compatibility/nx-version.d.ts +104 -0
  59. package/src/compatibility/nx-version.js +272 -0
  60. package/src/compatibility/nx-version.js.map +1 -0
  61. package/src/executors/affected-inputs.d.ts +29 -0
  62. package/src/executors/affected-inputs.js +259 -0
  63. package/src/executors/affected-inputs.js.map +1 -0
  64. package/src/executors/affected-run.d.ts +54 -0
  65. package/src/executors/affected-run.js +394 -0
  66. package/src/executors/affected-run.js.map +1 -0
  67. package/src/executors/affected.d.ts +239 -0
  68. package/src/executors/affected.js +589 -0
  69. package/src/executors/affected.js.map +1 -0
  70. package/src/executors/baseline-context.d.ts +85 -0
  71. package/src/executors/baseline-context.js +227 -0
  72. package/src/executors/baseline-context.js.map +1 -0
  73. package/src/executors/baseline.d.ts +123 -0
  74. package/src/executors/baseline.js +356 -0
  75. package/src/executors/baseline.js.map +1 -0
  76. package/src/executors/batch.d.ts +75 -0
  77. package/src/executors/batch.js +434 -0
  78. package/src/executors/batch.js.map +1 -0
  79. package/src/executors/build-records.d.ts +110 -0
  80. package/src/executors/build-records.js +267 -0
  81. package/src/executors/build-records.js.map +1 -0
  82. package/src/executors/cargo/executor.d.ts +28 -0
  83. package/src/executors/cargo/executor.js +58 -0
  84. package/src/executors/cargo/executor.js.map +1 -0
  85. package/src/executors/cargo/schema.json +54 -0
  86. package/src/executors/cargo-invocation.d.ts +81 -0
  87. package/src/executors/cargo-invocation.js +109 -0
  88. package/src/executors/cargo-invocation.js.map +1 -0
  89. package/src/executors/cargo-output.d.ts +212 -0
  90. package/src/executors/cargo-output.js +646 -0
  91. package/src/executors/cargo-output.js.map +1 -0
  92. package/src/executors/command.d.ts +318 -0
  93. package/src/executors/command.js +517 -0
  94. package/src/executors/command.js.map +1 -0
  95. package/src/executors/coverage-baseline.d.ts +23 -0
  96. package/src/executors/coverage-baseline.js +284 -0
  97. package/src/executors/coverage-baseline.js.map +1 -0
  98. package/src/executors/declared-options.d.ts +21 -0
  99. package/src/executors/declared-options.js +58 -0
  100. package/src/executors/declared-options.js.map +1 -0
  101. package/src/executors/digests.d.ts +94 -0
  102. package/src/executors/digests.js +190 -0
  103. package/src/executors/digests.js.map +1 -0
  104. package/src/executors/dotenv-check.d.ts +79 -0
  105. package/src/executors/dotenv-check.js +553 -0
  106. package/src/executors/dotenv-check.js.map +1 -0
  107. package/src/executors/group-invocations.d.ts +80 -0
  108. package/src/executors/group-invocations.js +253 -0
  109. package/src/executors/group-invocations.js.map +1 -0
  110. package/src/executors/group-run.d.ts +114 -0
  111. package/src/executors/group-run.js +591 -0
  112. package/src/executors/group-run.js.map +1 -0
  113. package/src/executors/groups.d.ts +113 -0
  114. package/src/executors/groups.js +285 -0
  115. package/src/executors/groups.js.map +1 -0
  116. package/src/executors/input-check.d.ts +52 -0
  117. package/src/executors/input-check.js +271 -0
  118. package/src/executors/input-check.js.map +1 -0
  119. package/src/executors/kept-files.d.ts +98 -0
  120. package/src/executors/kept-files.js +341 -0
  121. package/src/executors/kept-files.js.map +1 -0
  122. package/src/executors/lockfile/executor.d.ts +16 -0
  123. package/src/executors/lockfile/executor.js +37 -0
  124. package/src/executors/lockfile/executor.js.map +1 -0
  125. package/src/executors/lockfile/schema.json +50 -0
  126. package/src/executors/napi-build.d.ts +73 -0
  127. package/src/executors/napi-build.js +420 -0
  128. package/src/executors/napi-build.js.map +1 -0
  129. package/src/executors/nextest.d.ts +185 -0
  130. package/src/executors/nextest.js +498 -0
  131. package/src/executors/nextest.js.map +1 -0
  132. package/src/executors/nx-command.d.ts +95 -0
  133. package/src/executors/nx-command.js +205 -0
  134. package/src/executors/nx-command.js.map +1 -0
  135. package/src/executors/nx-task-files.d.ts +82 -0
  136. package/src/executors/nx-task-files.js +156 -0
  137. package/src/executors/nx-task-files.js.map +1 -0
  138. package/src/executors/print-test-mode.d.ts +1 -0
  139. package/src/executors/print-test-mode.js +25 -0
  140. package/src/executors/print-test-mode.js.map +1 -0
  141. package/src/executors/release-publish/executor.d.ts +24 -0
  142. package/src/executors/release-publish/executor.js +165 -0
  143. package/src/executors/release-publish/executor.js.map +1 -0
  144. package/src/executors/release-publish/schema.json +30 -0
  145. package/src/executors/run/executor.d.ts +12 -0
  146. package/src/executors/run/executor.js +27 -0
  147. package/src/executors/run/executor.js.map +1 -0
  148. package/src/executors/run/schema.json +45 -0
  149. package/src/executors/runner-script.d.ts +12 -0
  150. package/src/executors/runner-script.js +22 -0
  151. package/src/executors/runner-script.js.map +1 -0
  152. package/src/executors/runtime-input-check.d.ts +24 -0
  153. package/src/executors/runtime-input-check.js +87 -0
  154. package/src/executors/runtime-input-check.js.map +1 -0
  155. package/src/executors/shared-artifacts.d.ts +44 -0
  156. package/src/executors/shared-artifacts.js +132 -0
  157. package/src/executors/shared-artifacts.js.map +1 -0
  158. package/src/executors/split-words.d.ts +24 -0
  159. package/src/executors/split-words.js +111 -0
  160. package/src/executors/split-words.js.map +1 -0
  161. package/src/executors/stage.d.ts +163 -0
  162. package/src/executors/stage.js +526 -0
  163. package/src/executors/stage.js.map +1 -0
  164. package/src/executors/staged-run.d.ts +24 -0
  165. package/src/executors/staged-run.js +110 -0
  166. package/src/executors/staged-run.js.map +1 -0
  167. package/src/executors/task-env.d.ts +271 -0
  168. package/src/executors/task-env.js +494 -0
  169. package/src/executors/task-env.js.map +1 -0
  170. package/src/executors/task-execution.d.ts +61 -0
  171. package/src/executors/task-execution.js +122 -0
  172. package/src/executors/task-execution.js.map +1 -0
  173. package/src/executors/task-guards.d.ts +112 -0
  174. package/src/executors/task-guards.js +430 -0
  175. package/src/executors/task-guards.js.map +1 -0
  176. package/src/executors/task-options.d.ts +114 -0
  177. package/src/executors/task-options.js +258 -0
  178. package/src/executors/task-options.js.map +1 -0
  179. package/src/executors/task.d.ts +166 -0
  180. package/src/executors/task.js +520 -0
  181. package/src/executors/task.js.map +1 -0
  182. package/src/executors/test-mode.d.ts +182 -0
  183. package/src/executors/test-mode.js +391 -0
  184. package/src/executors/test-mode.js.map +1 -0
  185. package/src/executors/test-runner.d.ts +44 -0
  186. package/src/executors/test-runner.js +159 -0
  187. package/src/executors/test-runner.js.map +1 -0
  188. package/src/executors/test-steps.d.ts +109 -0
  189. package/src/executors/test-steps.js +535 -0
  190. package/src/executors/test-steps.js.map +1 -0
  191. package/src/executors/wasm-build.d.ts +56 -0
  192. package/src/executors/wasm-build.js +216 -0
  193. package/src/executors/wasm-build.js.map +1 -0
  194. package/src/generators/crate/binary.schema.json +28 -0
  195. package/src/generators/crate/crate.d.ts +24 -0
  196. package/src/generators/crate/crate.js +108 -0
  197. package/src/generators/crate/crate.js.map +1 -0
  198. package/src/generators/crate/enclosing-workspace.d.ts +25 -0
  199. package/src/generators/crate/enclosing-workspace.js +58 -0
  200. package/src/generators/crate/enclosing-workspace.js.map +1 -0
  201. package/src/generators/crate/library.schema.json +28 -0
  202. package/src/generators/init/graph-check.d.ts +81 -0
  203. package/src/generators/init/graph-check.js +299 -0
  204. package/src/generators/init/graph-check.js.map +1 -0
  205. package/src/generators/init/init.d.ts +23 -0
  206. package/src/generators/init/init.js +113 -0
  207. package/src/generators/init/init.js.map +1 -0
  208. package/src/generators/init/report.d.ts +19 -0
  209. package/src/generators/init/report.js +93 -0
  210. package/src/generators/init/report.js.map +1 -0
  211. package/src/generators/init/schema.json +9 -0
  212. package/src/graph/artifact-kinds.d.ts +29 -0
  213. package/src/graph/artifact-kinds.js +50 -0
  214. package/src/graph/artifact-kinds.js.map +1 -0
  215. package/src/graph/artifact-names.d.ts +97 -0
  216. package/src/graph/artifact-names.js +276 -0
  217. package/src/graph/artifact-names.js.map +1 -0
  218. package/src/graph/build-records.d.ts +74 -0
  219. package/src/graph/build-records.js +104 -0
  220. package/src/graph/build-records.js.map +1 -0
  221. package/src/graph/caching.d.ts +148 -0
  222. package/src/graph/caching.js +676 -0
  223. package/src/graph/caching.js.map +1 -0
  224. package/src/graph/collisions.d.ts +106 -0
  225. package/src/graph/collisions.js +156 -0
  226. package/src/graph/collisions.js.map +1 -0
  227. package/src/graph/computation-reports.d.ts +89 -0
  228. package/src/graph/computation-reports.js +216 -0
  229. package/src/graph/computation-reports.js.map +1 -0
  230. package/src/graph/declared-files.d.ts +190 -0
  231. package/src/graph/declared-files.js +600 -0
  232. package/src/graph/declared-files.js.map +1 -0
  233. package/src/graph/discovery.d.ts +175 -0
  234. package/src/graph/discovery.js +656 -0
  235. package/src/graph/discovery.js.map +1 -0
  236. package/src/graph/edges.d.ts +25 -0
  237. package/src/graph/edges.js +94 -0
  238. package/src/graph/edges.js.map +1 -0
  239. package/src/graph/entries.d.ts +83 -0
  240. package/src/graph/entries.js +259 -0
  241. package/src/graph/entries.js.map +1 -0
  242. package/src/graph/inputs.d.ts +420 -0
  243. package/src/graph/inputs.js +746 -0
  244. package/src/graph/inputs.js.map +1 -0
  245. package/src/graph/lockfile-task.d.ts +74 -0
  246. package/src/graph/lockfile-task.js +105 -0
  247. package/src/graph/lockfile-task.js.map +1 -0
  248. package/src/graph/names.d.ts +41 -0
  249. package/src/graph/names.js +34 -0
  250. package/src/graph/names.js.map +1 -0
  251. package/src/graph/napi.d.ts +107 -0
  252. package/src/graph/napi.js +206 -0
  253. package/src/graph/napi.js.map +1 -0
  254. package/src/graph/nx-glob.d.ts +36 -0
  255. package/src/graph/nx-glob.js +152 -0
  256. package/src/graph/nx-glob.js.map +1 -0
  257. package/src/graph/nx-internals.d.ts +57 -0
  258. package/src/graph/nx-internals.js +128 -0
  259. package/src/graph/nx-internals.js.map +1 -0
  260. package/src/graph/options.d.ts +32 -0
  261. package/src/graph/options.js +80 -0
  262. package/src/graph/options.js.map +1 -0
  263. package/src/graph/outputs.d.ts +75 -0
  264. package/src/graph/outputs.js +140 -0
  265. package/src/graph/outputs.js.map +1 -0
  266. package/src/graph/path-dependencies.d.ts +122 -0
  267. package/src/graph/path-dependencies.js +459 -0
  268. package/src/graph/path-dependencies.js.map +1 -0
  269. package/src/graph/plugin-package.d.ts +36 -0
  270. package/src/graph/plugin-package.js +132 -0
  271. package/src/graph/plugin-package.js.map +1 -0
  272. package/src/graph/plugin-version.d.ts +20 -0
  273. package/src/graph/plugin-version.js +153 -0
  274. package/src/graph/plugin-version.js.map +1 -0
  275. package/src/graph/projects.d.ts +141 -0
  276. package/src/graph/projects.js +182 -0
  277. package/src/graph/projects.js.map +1 -0
  278. package/src/graph/reached-projects.d.ts +46 -0
  279. package/src/graph/reached-projects.js +102 -0
  280. package/src/graph/reached-projects.js.map +1 -0
  281. package/src/graph/real-path.d.ts +47 -0
  282. package/src/graph/real-path.js +113 -0
  283. package/src/graph/real-path.js.map +1 -0
  284. package/src/graph/redirected-uses.d.ts +98 -0
  285. package/src/graph/redirected-uses.js +434 -0
  286. package/src/graph/redirected-uses.js.map +1 -0
  287. package/src/graph/registration.d.ts +121 -0
  288. package/src/graph/registration.js +233 -0
  289. package/src/graph/registration.js.map +1 -0
  290. package/src/graph/script-input.d.ts +46 -0
  291. package/src/graph/script-input.js +65 -0
  292. package/src/graph/script-input.js.map +1 -0
  293. package/src/graph/settings.d.ts +178 -0
  294. package/src/graph/settings.js +479 -0
  295. package/src/graph/settings.js.map +1 -0
  296. package/src/graph/target-defaults-causes.d.ts +33 -0
  297. package/src/graph/target-defaults-causes.js +202 -0
  298. package/src/graph/target-defaults-causes.js.map +1 -0
  299. package/src/graph/target-defaults-layers.d.ts +186 -0
  300. package/src/graph/target-defaults-layers.js +420 -0
  301. package/src/graph/target-defaults-layers.js.map +1 -0
  302. package/src/graph/target-defaults-meaning.d.ts +95 -0
  303. package/src/graph/target-defaults-meaning.js +292 -0
  304. package/src/graph/target-defaults-meaning.js.map +1 -0
  305. package/src/graph/target-defaults-report.d.ts +77 -0
  306. package/src/graph/target-defaults-report.js +242 -0
  307. package/src/graph/target-defaults-report.js.map +1 -0
  308. package/src/graph/target-defaults.d.ts +79 -0
  309. package/src/graph/target-defaults.js +425 -0
  310. package/src/graph/target-defaults.js.map +1 -0
  311. package/src/graph/target-fields.d.ts +16 -0
  312. package/src/graph/target-fields.js +134 -0
  313. package/src/graph/target-fields.js.map +1 -0
  314. package/src/graph/target-tables.d.ts +45 -0
  315. package/src/graph/target-tables.js +299 -0
  316. package/src/graph/target-tables.js.map +1 -0
  317. package/src/graph/targets.d.ts +367 -0
  318. package/src/graph/targets.js +404 -0
  319. package/src/graph/targets.js.map +1 -0
  320. package/src/graph/unification.d.ts +141 -0
  321. package/src/graph/unification.js +459 -0
  322. package/src/graph/unification.js.map +1 -0
  323. package/src/graph/unignored-directories.d.ts +25 -0
  324. package/src/graph/unignored-directories.js +89 -0
  325. package/src/graph/unignored-directories.js.map +1 -0
  326. package/src/graph/visibility.d.ts +17 -0
  327. package/src/graph/visibility.js +67 -0
  328. package/src/graph/visibility.js.map +1 -0
  329. package/src/graph/warnings.d.ts +38 -0
  330. package/src/graph/warnings.js +77 -0
  331. package/src/graph/warnings.js.map +1 -0
  332. package/src/graph/wasm.d.ts +56 -0
  333. package/src/graph/wasm.js +77 -0
  334. package/src/graph/wasm.js.map +1 -0
  335. package/src/index.d.ts +68 -0
  336. package/src/index.js +109 -0
  337. package/src/index.js.map +1 -0
  338. package/src/release/manifests.d.ts +95 -0
  339. package/src/release/manifests.js +164 -0
  340. package/src/release/manifests.js.map +1 -0
  341. package/src/release/places.d.ts +127 -0
  342. package/src/release/places.js +368 -0
  343. package/src/release/places.js.map +1 -0
  344. package/src/release/publish-cargo.d.ts +177 -0
  345. package/src/release/publish-cargo.js +351 -0
  346. package/src/release/publish-cargo.js.map +1 -0
  347. package/src/release/publish-crates.d.ts +124 -0
  348. package/src/release/publish-crates.js +242 -0
  349. package/src/release/publish-crates.js.map +1 -0
  350. package/src/release/publish-environments.d.ts +50 -0
  351. package/src/release/publish-environments.js +284 -0
  352. package/src/release/publish-environments.js.map +1 -0
  353. package/src/release/publish-messages.d.ts +66 -0
  354. package/src/release/publish-messages.js +273 -0
  355. package/src/release/publish-messages.js.map +1 -0
  356. package/src/release/publish-registry.d.ts +27 -0
  357. package/src/release/publish-registry.js +135 -0
  358. package/src/release/publish-registry.js.map +1 -0
  359. package/src/release/publish-settings.d.ts +26 -0
  360. package/src/release/publish-settings.js +56 -0
  361. package/src/release/publish-settings.js.map +1 -0
  362. package/src/release/publish.d.ts +59 -0
  363. package/src/release/publish.js +620 -0
  364. package/src/release/publish.js.map +1 -0
  365. package/src/release/repository.d.ts +73 -0
  366. package/src/release/repository.js +219 -0
  367. package/src/release/repository.js.map +1 -0
  368. package/src/release/requirements.d.ts +34 -0
  369. package/src/release/requirements.js +30 -0
  370. package/src/release/requirements.js.map +1 -0
  371. package/src/release/toml-edit.d.ts +67 -0
  372. package/src/release/toml-edit.js +453 -0
  373. package/src/release/toml-edit.js.map +1 -0
  374. package/src/release/version-actions.d.ts +133 -0
  375. package/src/release/version-actions.js +474 -0
  376. package/src/release/version-actions.js.map +1 -0
  377. package/src/release/version-checks.d.ts +21 -0
  378. package/src/release/version-checks.js +151 -0
  379. package/src/release/version-checks.js.map +1 -0
  380. package/src/release/version-lockfiles.d.ts +61 -0
  381. package/src/release/version-lockfiles.js +222 -0
  382. package/src/release/version-lockfiles.js.map +1 -0
  383. package/src/tools/napi-cli.d.ts +70 -0
  384. package/src/tools/napi-cli.js +63 -0
  385. package/src/tools/napi-cli.js.map +1 -0
  386. package/src/tools/optional-tools.d.ts +121 -0
  387. package/src/tools/optional-tools.js +303 -0
  388. package/src/tools/optional-tools.js.map +1 -0
  389. package/src/tools/print-napi-cli.d.ts +1 -0
  390. package/src/tools/print-napi-cli.js +24 -0
  391. package/src/tools/print-napi-cli.js.map +1 -0
@@ -0,0 +1,520 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.TaskError = exports.projectWarnings = exports.groupInvocations = exports.checksAfterCargo = void 0;
4
+ exports.runTask = runTask;
5
+ exports.prepareTask = prepareTask;
6
+ const tslib_1 = require("tslib");
7
+ const node_path_1 = require("node:path");
8
+ const node_util_1 = require("node:util");
9
+ const collisions_1 = require("../graph/collisions");
10
+ const lockfile_task_1 = require("../graph/lockfile-task");
11
+ const outputs_1 = require("../graph/outputs");
12
+ const targets_1 = require("../graph/targets");
13
+ const optional_tools_1 = require("../tools/optional-tools");
14
+ const cargo_invocation_1 = require("./cargo-invocation");
15
+ const command_1 = require("./command");
16
+ const digests_1 = require("./digests");
17
+ const dotenv_check_1 = require("./dotenv-check");
18
+ const group_invocations_1 = require("./group-invocations");
19
+ Object.defineProperty(exports, "groupInvocations", { enumerable: true, get: function () { return group_invocations_1.groupInvocations; } });
20
+ const group_run_1 = require("./group-run");
21
+ const groups_1 = require("./groups");
22
+ const napi_build_1 = require("./napi-build");
23
+ const nx_command_1 = require("./nx-command");
24
+ const nx_task_files_1 = require("./nx-task-files");
25
+ const runtime_input_check_1 = require("./runtime-input-check");
26
+ const shared_artifacts_1 = require("./shared-artifacts");
27
+ const stage_1 = require("./stage");
28
+ const staged_run_1 = require("./staged-run");
29
+ const task_env_1 = require("./task-env");
30
+ const task_execution_1 = require("./task-execution");
31
+ Object.defineProperty(exports, "checksAfterCargo", { enumerable: true, get: function () { return task_execution_1.checksAfterCargo; } });
32
+ const task_guards_1 = require("./task-guards");
33
+ Object.defineProperty(exports, "projectWarnings", { enumerable: true, get: function () { return task_guards_1.projectWarnings; } });
34
+ Object.defineProperty(exports, "TaskError", { enumerable: true, get: function () { return task_guards_1.TaskError; } });
35
+ const task_options_1 = require("./task-options");
36
+ const test_mode_1 = require("./test-mode");
37
+ const wasm_build_1 = require("./wasm-build");
38
+ /**
39
+ * The profiles whose artifacts Cargo puts in another profile's folder, which
40
+ * the outputs of `build` and `doc` cannot name (`DES-OUTPUTS`), with what to
41
+ * build with instead.
42
+ */
43
+ const renamedProfiles = {
44
+ dev: "no profile: dev is cargo's default profile, whose folder is debug",
45
+ test: "no profile, which builds the dev profile into the same folder, debug, or a custom profile that inherits from test",
46
+ bench: "the profile release, whose folder cargo uses for bench too, or a custom profile that inherits from bench",
47
+ };
48
+ /**
49
+ * The tool besides cargo that a target runs, by the target's default name:
50
+ * a cargo subcommand that the plugin never installs (`ADR-V1-SCOPE`).
51
+ */
52
+ const targetTools = {
53
+ audit: "cargo-audit",
54
+ deny: "cargo-deny",
55
+ "hakari-check": "cargo-hakari",
56
+ "coverage-baseline": "cargo-affected",
57
+ };
58
+ /**
59
+ * Runs one task of an inferred target that Nx runs on its own, as with
60
+ * `--batch=false`: as a group with one task (`TERM-GROUP`), in the root
61
+ * folder of the crate's workspace, with the environment that Nx gives the
62
+ * task and nothing added.
63
+ *
64
+ * A group that selects its crate, a group of one crate among them, runs one
65
+ * cargo command with cargo's standard streams as the task's own, so that Nx
66
+ * shows and stores what cargo prints, and the task succeeds when cargo exits
67
+ * with status 0. A group that selects the whole workspace, as `build`,
68
+ * `check`, `lint` and `test` do under `workspace-build` on the host, runs the
69
+ * steps that the same group runs in a batch, so that its crate compiles with
70
+ * the features of the whole workspace whatever else runs
71
+ * (`REQ-STABLE-FEATURES`), and prints its part of their output once they
72
+ * have ended, as its result in a batch holds it (`DES-BATCH`).
73
+ *
74
+ * A problem found before cargo starts fails the task with a message that
75
+ * names it and runs no cargo. An option that the task ignores gets a warning
76
+ * line at the top of its output, and so does the reason why a task runs its
77
+ * crate alone where the output names it. Before anything else, the task
78
+ * prints the warnings that graph creation found for its project, among them
79
+ * the one for an Nx major newer than the supported ones that
80
+ * `NX_RUST_ALLOW_UNSUPPORTED_NX` lets the plugin run with, which the Nx
81
+ * daemon keeps out of the terminal. The project's keys hold a digest of them,
82
+ * so that a cache hit replays the warnings of the graph that the command
83
+ * uses (`DES-DIAGNOSTICS`, "Warnings where they are seen"), apart from those
84
+ * about Cargo configuration that Nx does not hash, which no key holds. When
85
+ * the executor's context says that Nx runs verbosely, the task prints each
86
+ * cargo command right before cargo starts, after every warning
87
+ * (`DES-INVOCATION`, "Printing the command"); otherwise it prints nothing of
88
+ * it.
89
+ */
90
+ // @mara implements DES-INVOCATION
91
+ // @mara implements REQ-CARGO-UNCHANGED
92
+ // @mara implements REQ-NO-MANIFEST-WRITES
93
+ // @mara implements REQ-VERBOSE-COMMAND
94
+ // @mara implements REQ-STABLE-FEATURES
95
+ function runTask(executor, options, context) {
96
+ return tslib_1.__awaiter(this, void 0, void 0, function* () {
97
+ var _a, _b, _c, _d;
98
+ for (const warning of (0, task_guards_1.projectWarnings)(context)) {
99
+ console.warn(warning);
100
+ }
101
+ // The task's environment without the variables by which Nx tells the task
102
+ // how it runs and records it, which a batch cannot give its tasks: every
103
+ // check and every cargo command of the task uses it, as in a batch
104
+ // (`DES-BATCH`).
105
+ let prepared;
106
+ let planned;
107
+ let invocation;
108
+ let env;
109
+ try {
110
+ try {
111
+ env = (0, task_env_1.withoutUnloadedRootValues)((0, task_env_1.cargoTaskEnvironment)(process.env, (0, task_guards_1.singleTaskShape)(context)), context.root);
112
+ }
113
+ catch (error) {
114
+ if (!(error instanceof task_env_1.TaskEnvironmentError)) {
115
+ throw error;
116
+ }
117
+ throw new task_guards_1.TaskError(`${context.projectName}:${context.targetName}: @convesoft/nx-rust cannot build this task's environment, because ${error.message}. The task does not run, so that Nx stores no result for it. Use an Nx version that @convesoft/nx-rust supports.`);
118
+ }
119
+ prepared = prepareTask(executor, options, context, env);
120
+ // Two builds of one crate into one folder in one command, which no stage
121
+ // keeps apart, fail before cargo runs, as in a batch (`DES-BATCH`, "Files
122
+ // that a batch stores").
123
+ const graphTask = prepared.target === "build" ? (0, task_guards_1.graphTaskOf)(context) : undefined;
124
+ const refused = graphTask === undefined
125
+ ? undefined
126
+ : (0, stage_1.sharedBuildFolders)([graphTask.id], context).get(graphTask.id);
127
+ if (refused !== undefined) {
128
+ throw new task_guards_1.TaskError(refused);
129
+ }
130
+ [planned] = (0, groups_1.planGroups)([[prepared]]);
131
+ const [finished] = (0, group_invocations_1.groupInvocations)([prepared], context.root, planned.selection);
132
+ if (typeof finished === "string") {
133
+ throw new task_guards_1.TaskError(finished);
134
+ }
135
+ invocation = finished;
136
+ }
137
+ catch (error) {
138
+ if (error instanceof task_guards_1.TaskError) {
139
+ console.error(error.message);
140
+ return { success: false };
141
+ }
142
+ throw error;
143
+ }
144
+ for (const warning of prepared.warnings) {
145
+ console.warn(warning);
146
+ }
147
+ if (((_a = prepared.testMode) === null || _a === void 0 ? void 0 : _a.note) !== undefined) {
148
+ console.warn(prepared.testMode.note);
149
+ }
150
+ if (planned.selection.kind === "alone" && planned.selection.note !== undefined) {
151
+ console.warn(planned.selection.note);
152
+ }
153
+ const task = `${(_b = context.projectName) !== null && _b !== void 0 ? _b : ""}:${(_c = context.targetName) !== null && _c !== void 0 ? _c : ""}`;
154
+ const verbose = (0, cargo_invocation_1.taskRunsVerbosely)(context);
155
+ // `napi-build` runs its compile with variables of its own and its
156
+ // post-processing after it, and `wasm-build` the wasm-bindgen CLI after its
157
+ // compile, whichever way their groups select (`DES-NAPI`, `DES-WASM`). A
158
+ // task that selects affected tests runs steps 1 and 2 before its nextest
159
+ // command (`DES-TEST-RUN`), as in a batch.
160
+ if (planned.selection.kind === "workspace" ||
161
+ prepared.napi !== undefined ||
162
+ prepared.wasm !== undefined ||
163
+ ((_d = prepared.testMode) === null || _d === void 0 ? void 0 : _d.selects) === true) {
164
+ // A whole-workspace `build` and the compile of `napi-build` and
165
+ // `wasm-build` build in a stage of their own, as in a batch (`DES-BATCH`,
166
+ // "Staged builds").
167
+ const [result] = yield (0, staged_run_1.runTargetGroup)([{ prepared, invocation, context }], planned.selection, verbose);
168
+ if (result.output !== "") {
169
+ yield new Promise((resolve) => process.stdout.write(`${result.output}\n`, () => resolve()));
170
+ }
171
+ return { success: result.success };
172
+ }
173
+ // Every step of the group, one after another, each only after the one
174
+ // before it succeeded: one for most targets, two for `hakari-check`, and
175
+ // for `test` with nextest the doctests only where the crate has a library.
176
+ for (const step of invocation.steps.filter((entry) => entry.kind !== "doctests" || (0, group_run_1.hasLibrary)(invocation.package))) {
177
+ if (!(yield (0, task_execution_1.runCargo)(Object.assign(Object.assign({}, invocation), { args: step.args }), env, verbose ? task : undefined))) {
178
+ if (prepared.target === "hakari-check") {
179
+ console.error((0, task_execution_1.hakariCheckFailure)(task, step.args));
180
+ }
181
+ return { success: false };
182
+ }
183
+ }
184
+ // As after a group's cargo calls (runGroup): the check lists the files as
185
+ // cargo left them, whatever in this process read Nx's workspace context
186
+ // before (`DES-BUILD-INPUT-CHECK`, point 5). Nothing does in Nx 24.0.6,
187
+ // which leaves the reset nothing to clear.
188
+ if (invocation.inputCheck !== undefined) {
189
+ (0, nx_task_files_1.resetNxWorkspaceContext)(context.root);
190
+ }
191
+ const { failures, warnings } = yield (0, task_execution_1.checksAfterCargo)(invocation, context);
192
+ for (const warning of warnings) {
193
+ console.warn(warning);
194
+ }
195
+ for (const failure of failures) {
196
+ console.error(failure);
197
+ }
198
+ return { success: failures.length === 0 };
199
+ });
200
+ }
201
+ /**
202
+ * The checks of a task before cargo runs, and what its command depends on,
203
+ * apart from what a group asks cargo once for all its tasks: the crates'
204
+ * package ID specifications and Cargo's directories ({@link groupInvocations}).
205
+ *
206
+ * @param env The task's environment, with `NX_RUST_LOCKED`, `NX_RUST_RUN_ID`
207
+ * and the record of the `nx` command ({@link recordedNxCommand}).
208
+ * @throws {TaskError} When the target is no inferred target of this
209
+ * executor, when its configuration caches a target that the plugin leaves
210
+ * uncached in this project, when `build` or `doc` gets the profile `dev`,
211
+ * `test` or `bench`, or is cached while its options name no triple and
212
+ * the task's environment and Cargo's configuration pick a triple whose
213
+ * folder the plugin cannot name or other triples than its outputs name,
214
+ * or is cached while its `targetTriple` option is `host-tuple` or a
215
+ * target specification file (`DES-OUTPUTS`), when `NX_RUST_LOCKED` is
216
+ * neither `true` nor `false`, when `args` does not split into words, when
217
+ * the run gives `pluginVersion` another value than the target's
218
+ * (`DES-PLUGIN-OPTIONS`), when a task whose target hashes digests does not
219
+ * depend on its workspace's lockfile task in a run that does not exclude
220
+ * task dependencies (`DES-LOCKFILE-HASHING`), when the run holds the
221
+ * `build` of a crate whose `test` replaces its executables without an
222
+ * order between the two (`DES-TARGETS`), or when the tool that the target
223
+ * runs besides cargo is not installed where `env` and the workspace root
224
+ * say (`DES-DIAGNOSTICS`), or when `NX_RUST_TEST_MODE` has another value
225
+ * than `full` or `affected` for a `test` in a workspace that uses
226
+ * selection (`DES-TEST-MODE`). The checks of what reaches the task's key, the
227
+ * cache guard, `pluginVersion` and the lockfile dependency, and the check
228
+ * of the order of `test` and `build` all run before the check for the tool.
229
+ */
230
+ // @mara implements DES-OUTPUTS
231
+ // @mara implements DES-PLUGIN-OPTIONS
232
+ // @mara implements DES-DIAGNOSTICS
233
+ // @mara implements DES-TEST-MODE
234
+ function prepareTask(executor, options, context, env) {
235
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5, _6, _7, _8, _9, _10, _11;
236
+ const projectName = (_a = context.projectName) !== null && _a !== void 0 ? _a : "";
237
+ const targetName = (_b = context.targetName) !== null && _b !== void 0 ? _b : "";
238
+ const task = `${projectName}:${targetName}`;
239
+ const metadata = (0, task_guards_1.targetMetadata)((_d = (_c = context.target) === null || _c === void 0 ? void 0 : _c.metadata) === null || _d === void 0 ? void 0 : _d[targets_1.targetCargoMetadataKey]);
240
+ if (metadata === undefined || !executor.serves(metadata.target)) {
241
+ throw new task_guards_1.TaskError(`${task}: ${executor.name} runs only the targets that @convesoft/nx-rust infers for a crate or a Cargo workspace, and ${task} is not one of them. To run another cargo command, define a target with a "command" under a name of its own.`);
242
+ }
243
+ // Dotenv files whose expansion would differ between the ways of running
244
+ // the task (`DES-BATCH`, "Dotenv files").
245
+ let dotenv;
246
+ try {
247
+ if (context.projectGraph === undefined) {
248
+ throw new task_env_1.TaskEnvironmentError("Nx gave the task no project graph");
249
+ }
250
+ dotenv = (0, dotenv_check_1.dotenvProblem)({
251
+ id: task,
252
+ target: Object.assign({ project: projectName, target: targetName }, (context.configurationName === undefined
253
+ ? {}
254
+ : { configuration: context.configurationName })),
255
+ projectRoot: (_g = (_f = (_e = context.projectsConfigurations) === null || _e === void 0 ? void 0 : _e.projects) === null || _f === void 0 ? void 0 : _f[projectName]) === null || _g === void 0 ? void 0 : _g.root,
256
+ }, context.projectGraph, context.root, env);
257
+ }
258
+ catch (error) {
259
+ if (!(error instanceof task_env_1.TaskEnvironmentError)) {
260
+ throw error;
261
+ }
262
+ throw new task_guards_1.TaskError(`${task}: @convesoft/nx-rust cannot check the dotenv files of this task, because ${error.message}. The task does not run, so that Nx stores no result for it. Use an Nx version that @convesoft/nx-rust supports.`);
263
+ }
264
+ if (dotenv !== undefined) {
265
+ throw new task_guards_1.TaskError(`${task}: ${dotenv}`);
266
+ }
267
+ // What the plugin decided for this project's target; a graph from before
268
+ // that decision was recorded falls back to the target's default name.
269
+ const uncached = (_h = metadata.uncached) !== null && _h !== void 0 ? _h : (targets_1.cachedTargets.has(metadata.target)
270
+ ? undefined
271
+ : ((_j = outputs_1.uncachedByDesign[metadata.target]) !== null && _j !== void 0 ? _j : "the plugin does not cache this target"));
272
+ if (((_k = context.target) === null || _k === void 0 ? void 0 : _k.cache) === true && uncached !== undefined) {
273
+ throw new task_guards_1.TaskError([
274
+ `${task}: the configuration of this target sets "cache": true, but @convesoft/nx-rust leaves \`${metadata.target}\` uncached in this project, because ${uncached}. The task does not run, so that Nx stores no result for it.`,
275
+ `The setting comes from the workspace's configuration: run \`nx show target ${task} --json\` and look under \`sourceMap\` for the file and entry. If it is a \`targetDefaults\` entry in nx.json, add a \`filter\` to it or add an empty entry keyed by "${(_l = context.target.executor) !== null && _l !== void 0 ? _l : executor.name}".`,
276
+ ].join("\n"));
277
+ }
278
+ // A file of this task that another project's target writes too, where
279
+ // graph creation did not see that project (`DES-OUTPUTS`, "Files of one
280
+ // name"): only a task that Nx caches can store it.
281
+ const shared = ((_m = context.target) === null || _m === void 0 ? void 0 : _m.cache) === true &&
282
+ (metadata.target === "build" ||
283
+ metadata.target === "doc" ||
284
+ (metadata.target === "test" && metadata.waitsForBuild === true))
285
+ ? (0, shared_artifacts_1.sharedArtifact)((_p = (_o = context.projectsConfigurations) === null || _o === void 0 ? void 0 : _o.projects) !== null && _p !== void 0 ? _p : {}, {
286
+ task,
287
+ project: projectName,
288
+ target: metadata.target,
289
+ })
290
+ : undefined;
291
+ if (shared !== undefined) {
292
+ throw new task_guards_1.TaskError((0, shared_artifacts_1.sharedArtifactMessage)({ task, project: projectName, target: metadata.target }, shared));
293
+ }
294
+ if (metadata.target === "build" || metadata.target === "doc") {
295
+ const replacement = options.profile === undefined ? undefined : renamedProfiles[options.profile];
296
+ if (replacement !== undefined) {
297
+ throw new task_guards_1.TaskError(`${task}: the profile ${options.profile} puts cargo's artifacts in the folder of another profile, which @convesoft/nx-rust cannot name for the cache. Build with ${replacement}.`);
298
+ }
299
+ // The outputs take the option's value for the triple's folder, which
300
+ // cargo names otherwise for some values (`DES-OUTPUTS`).
301
+ if (((_q = context.target) === null || _q === void 0 ? void 0 : _q.cache) === true && (0, task_guards_1.namesTriple)(options)) {
302
+ (0, task_guards_1.checkOptionTriple)(task, metadata.target, options.targetTriple, context, env);
303
+ }
304
+ // The outputs name the folder of the triple in the option, and else of
305
+ // what the configuration and the graph's environment picked, unless
306
+ // the plugin cannot name that (`DES-OUTPUTS`).
307
+ if (((_r = context.target) === null || _r === void 0 ? void 0 : _r.cache) === true &&
308
+ !(0, task_guards_1.namesTriple)(options) &&
309
+ metadata.tripleProblem !== undefined) {
310
+ throw new task_guards_1.TaskError(`${task}: ${metadata.tripleProblem}, and this run of the cached ${metadata.target} names no triple in the targetTriple option. Run it with the triple that the target's options give, and remove what clears the option for this run, such as a configuration, a project.json, a targetDefaults entry or a value on the command line; \`nx show target ${task} --json\` shows where each option comes from. The task does not run, so that Nx stores no result for it.`);
311
+ }
312
+ }
313
+ const project = (_t = (_s = context.projectsConfigurations) === null || _s === void 0 ? void 0 : _s.projects) === null || _t === void 0 ? void 0 : _t[projectName];
314
+ const cargo = project === undefined ? undefined : (0, collisions_1.cargoMetadataOf)(project);
315
+ if (cargo === undefined) {
316
+ throw new task_guards_1.TaskError(`${task}: the project carries no Cargo workspace in its metadata, which @convesoft/nx-rust gives each project that it creates. Make sure that a project.json or package.json in the folder ${(_u = project === null || project === void 0 ? void 0 : project.root) !== null && _u !== void 0 ? _u : projectName} does not replace the project's "metadata".`);
317
+ }
318
+ const locked = (0, task_guards_1.lockedMode)(metadata.locked, env.NX_RUST_LOCKED);
319
+ const strategy = (_v = cargo.featureUnification) !== null && _v !== void 0 ? _v : "workspace-build";
320
+ const configured = (0, task_guards_1.configuredOptions)(context);
321
+ let examined;
322
+ try {
323
+ examined = (0, task_options_1.taskOptions)({
324
+ task,
325
+ target: metadata.target,
326
+ executor,
327
+ options: options,
328
+ configured,
329
+ graphTask: (0, task_guards_1.graphTaskOf)(context),
330
+ record: (0, nx_command_1.recordedNxCommand)(env),
331
+ workspaceRoot: context.root,
332
+ });
333
+ }
334
+ catch (error) {
335
+ throw error instanceof task_options_1.OptionError ? new task_guards_1.TaskError(error.message) : error;
336
+ }
337
+ // Graph creation has checked the target's own value; a value for this run
338
+ // alone comes from the command line or from a task that forwards its
339
+ // options. Words after `--` that `run` passes to its binary are no option.
340
+ const given = examined.options.pluginVersion;
341
+ if (given !== undefined && !(0, node_util_1.isDeepStrictEqual)(given, configured[command_1.pluginVersionOption])) {
342
+ throw new task_guards_1.TaskError(`${task}: this run gives the option "pluginVersion" the value ${JSON.stringify(given)}, but only @convesoft/nx-rust sets that option, to carry its version into the cache key. The value comes from the command line, such as --pluginVersion, or from a task that forwards its options to this one: leave it out. The task does not run, so that Nx stores no result for it.`);
343
+ }
344
+ if (metadata.target === "test") {
345
+ // The crates whose `build` the test waits for; a graph from before the
346
+ // list was recorded names the crate's own `build` alone.
347
+ const project = (_x = (_w = context.projectsConfigurations) === null || _w === void 0 ? void 0 : _w.projects) === null || _x === void 0 ? void 0 : _x[projectName];
348
+ const roots = (_y = metadata.waitsForBuilds) !== null && _y !== void 0 ? _y : (metadata.waitsForBuild === true && project !== undefined ? [project.root] : []);
349
+ if (roots.length > 0) {
350
+ (0, task_guards_1.checkBuildOrder)(task, context, roots);
351
+ }
352
+ }
353
+ // Whether the key holds the lockfile task's digests, which the task then
354
+ // checks after cargo's call; a key without them fails the task here.
355
+ const workspaceRoot = (0, node_path_1.dirname)(cargo.workspaceManifest);
356
+ const cwd = (0, node_path_1.join)(context.root, workspaceRoot);
357
+ if ((metadata.target === "build" || metadata.target === "doc") &&
358
+ ((_z = context.target) === null || _z === void 0 ? void 0 : _z.cache) === true &&
359
+ !(0, task_guards_1.namesTriple)(options)) {
360
+ (0, task_guards_1.checkPickedTriples)(task, metadata, cwd, context.root, env);
361
+ }
362
+ const lockfile = (0, node_path_1.join)(cwd, "Cargo.lock");
363
+ const folder = (0, node_path_1.join)(context.root, (0, lockfile_task_1.digestFolder)(workspaceRoot));
364
+ // The private copies of this nx command's lockfile tasks.
365
+ const commandId = ((_0 = env[lockfile_task_1.commandIdVariable]) !== null && _0 !== void 0 ? _0 : "").replace(/[^A-Za-z0-9-]/g, "");
366
+ const commandFolder = commandId === ""
367
+ ? undefined
368
+ : (0, node_path_1.join)(context.root, (0, lockfile_task_1.commandDigestFolder)(workspaceRoot, commandId));
369
+ let digests;
370
+ if (metadata.target === "lockfile") {
371
+ digests = { kind: "write", lockfile, folder, commandFolder, members: (_1 = metadata.members) !== null && _1 !== void 0 ? _1 : [] };
372
+ }
373
+ else if (metadata.digests !== undefined) {
374
+ const lockfileTask = (0, task_guards_1.keyHoldsDigests)(context, cargo.workspaceManifest, env);
375
+ if (lockfileTask !== undefined) {
376
+ const members = (0, digests_1.heldMembers)(metadata.digests, metadata.everyDigest === true, lockfileTask.members);
377
+ if (members === undefined) {
378
+ throw new task_guards_1.TaskError(`${task}: the cache key of this task holds the digests of every member of its Cargo workspace, ${workspaceRoot === "." ? "at the repository root" : `in ${workspaceRoot}`}, but the metadata of the lockfile task ${lockfileTask.id} names no member, so nx-rust cannot check them after cargo's call. The task does not run, so that Nx stores no result for it. Run \`nx reset\` so that Nx creates the project graph again.`);
379
+ }
380
+ // Under `hakari`, a task that shares its command compares every
381
+ // member's digest, although its key holds its own: its result rests
382
+ // on the drift check, which judged the whole lockfile
383
+ // (`DES-LOCKFILE-HASHING`, "Post-check").
384
+ const shared = strategy === "hakari"
385
+ ? (0, digests_1.heldMembers)(metadata.digests, true, lockfileTask.members)
386
+ : undefined;
387
+ if (strategy === "hakari" && shared === undefined) {
388
+ throw new task_guards_1.TaskError(`${task}: this task compares the digests of every member of its Cargo workspace, ${workspaceRoot === "." ? "at the repository root" : `in ${workspaceRoot}`}, after a cargo command that it shares with other crates, but the metadata of the lockfile task ${lockfileTask.id} names no member, so nx-rust cannot check them after cargo's call. The task does not run, so that Nx stores no result for it. Run \`nx reset\` so that Nx creates the project graph again.`);
389
+ }
390
+ if (strategy === "hakari" && metadata.target !== "doc") {
391
+ (0, task_guards_1.checkHakariDependency)(context, cargo.workspaceManifest);
392
+ }
393
+ digests = Object.assign(Object.assign({ kind: "check", task,
394
+ lockfile,
395
+ folder,
396
+ commandFolder,
397
+ members }, (shared === undefined ? {} : { sharedMembers: shared })), { workspace: workspaceRoot });
398
+ }
399
+ }
400
+ // The test mode, by the rule of the mode input that the key holds, from
401
+ // the task's own environment; a task run on its own and one in a batch
402
+ // get the same (`DES-TEST-MODE`).
403
+ let testModeDecision;
404
+ if (metadata.target === "test" && metadata.affectedTests !== true) {
405
+ // Graph creation refuses the option set to true in stored configuration,
406
+ // so a value here comes from the command line or a forwarding task
407
+ // (`DES-PLUGIN-OPTIONS`).
408
+ if (examined.options.affectedTests === true) {
409
+ throw new task_guards_1.TaskError(`${task}: this run sets "affectedTests" to true, as --affectedTests=true on the command line does, but the Cargo workspace in ${cargo.workspaceManifest} does not use the selection of affected tests, so the option can only turn it off. Remove it, or turn selection on with affectedTests = true under [workspace.metadata.nx] in ${cargo.workspaceManifest}. The task does not run, so that Nx stores no result for it.`);
410
+ }
411
+ }
412
+ if (metadata.target === "test" && metadata.affectedTests === true) {
413
+ const mode = (0, test_mode_1.testMode)(env, cwd);
414
+ if (mode.kind === "invalid") {
415
+ throw new task_guards_1.TaskError((0, test_mode_1.invalidTestModeMessage)(task, mode.value));
416
+ }
417
+ const optedOut = examined.options.affectedTests === false;
418
+ const selects = mode.kind === "affected" && !optedOut;
419
+ const neededBy = `the selection of affected tests of the ${targetName} target of ${(_2 = cargo.packageName) !== null && _2 !== void 0 ? _2 : projectName}, whose Cargo workspace in ${(0, optional_tools_1.describeFolder)(workspaceRoot)} turns it on (affectedTests), in test mode ${(0, test_mode_1.testModeText)(mode)}`;
420
+ let missing;
421
+ try {
422
+ (0, optional_tools_1.requireTool)("cargo-affected", neededBy, {
423
+ workspaceRoot: context.root,
424
+ workspaces: [],
425
+ env,
426
+ folder: cwd,
427
+ });
428
+ }
429
+ catch (error) {
430
+ if (!(error instanceof optional_tools_1.MissingToolError)) {
431
+ throw error;
432
+ }
433
+ // In affected mode the task cannot select without it; in mode full it
434
+ // runs the full suite, and the missing tool would show only in a run
435
+ // that selects (`DES-DIAGNOSTICS`).
436
+ if (selects) {
437
+ throw new task_guards_1.TaskError(`${task}: ${error.message}`);
438
+ }
439
+ missing = `${task}: warning: cargo-affected is not installed, which the selection of affected tests in this workspace needs in test mode affected; this run is in test mode ${(0, test_mode_1.testModeText)(mode)} and runs the full suite without it. ${error.tool.install}`;
440
+ }
441
+ const note = [(0, test_mode_1.testModeNote)(task, mode, optedOut), missing]
442
+ .filter((line) => line !== undefined)
443
+ .join("\n");
444
+ testModeDecision = Object.assign({ mode, selects }, (note === "" ? {} : { note }));
445
+ }
446
+ // The checks of `napi-build` before cargo (`DES-NAPI`), after those of
447
+ // what reaches the task's key.
448
+ let napi;
449
+ if (metadata.target === "napi-build" && cargo.packageName !== undefined) {
450
+ try {
451
+ napi = (0, napi_build_1.prepareNapiTask)(task, cargo.packageName, metadata, (0, node_path_1.join)(context.root, (_3 = project === null || project === void 0 ? void 0 : project.root) !== null && _3 !== void 0 ? _3 : ""), cwd, env, ((_4 = context.target) === null || _4 === void 0 ? void 0 : _4.cache) === true, context.root);
452
+ }
453
+ catch (error) {
454
+ throw error instanceof napi_build_1.NapiTaskError ? new task_guards_1.TaskError(error.message) : error;
455
+ }
456
+ }
457
+ // The checks of `wasm-build` before cargo (`DES-WASM`), after those of
458
+ // what reaches the task's key.
459
+ let wasm;
460
+ if (metadata.target === "wasm-build" && cargo.packageName !== undefined) {
461
+ try {
462
+ wasm = (0, wasm_build_1.prepareWasmTask)(task, cargo.packageName, metadata, (0, node_path_1.join)(context.root, (_5 = project === null || project === void 0 ? void 0 : project.root) !== null && _5 !== void 0 ? _5 : ""), cwd, env, examined.options, context.root, (_7 = (_6 = metadata.digests) === null || _6 === void 0 ? void 0 : _6.find((member) => member.name === cargo.packageName)) === null || _7 === void 0 ? void 0 : _7.version);
463
+ }
464
+ catch (error) {
465
+ throw error instanceof wasm_build_1.WasmTaskError ? new task_guards_1.TaskError(error.message) : error;
466
+ }
467
+ }
468
+ const nextest = metadata.target === "test" && metadata.testRunner === "nextest";
469
+ const tool = nextest ? "cargo-nextest" : targetTools[metadata.target];
470
+ if (tool !== undefined) {
471
+ const neededBy = nextest
472
+ ? `the ${targetName} target of ${(_8 = cargo.packageName) !== null && _8 !== void 0 ? _8 : projectName}, whose Cargo workspace in ${(0, optional_tools_1.describeFolder)(workspaceRoot)} uses the nextest runner (testRunner)`
473
+ : `the ${targetName} target of the Cargo workspace in ${(0, optional_tools_1.describeFolder)(workspaceRoot)}`;
474
+ try {
475
+ (0, optional_tools_1.requireTool)(tool, neededBy, {
476
+ workspaceRoot: context.root,
477
+ workspaces: [],
478
+ env,
479
+ folder: cwd,
480
+ });
481
+ }
482
+ catch (error) {
483
+ throw error instanceof optional_tools_1.MissingToolError ? new task_guards_1.TaskError(`${task}: ${error.message}`) : error;
484
+ }
485
+ }
486
+ return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({ task, target: metadata.target, options: examined.options, binaryArguments: examined.binaryArguments,
487
+ // Last, once every check that fails the task has passed.
488
+ warnings: [
489
+ ...examined.warnings,
490
+ ...(0, runtime_input_check_1.failedInputWarnings)(task, (_9 = context.target) === null || _9 === void 0 ? void 0 : _9.inputs, context.root, env),
491
+ ], locked,
492
+ workspaceRoot,
493
+ cwd }, (cargo.packageName === undefined
494
+ ? {}
495
+ : { crate: cargo.packageName, manifest: cargo.manifest })), (digests === undefined ? {} : { digests })), ((metadata.target === "build" || metadata.target === "doc") &&
496
+ ((_10 = context.target) === null || _10 === void 0 ? void 0 : _10.cache) === true &&
497
+ metadata.artifactDirectory !== undefined
498
+ ? { artifactCheck: metadata }
499
+ : {})), ((metadata.target === "build" ||
500
+ metadata.target === "napi-build" ||
501
+ metadata.target === "wasm-build") &&
502
+ metadata.records !== undefined
503
+ ? { records: metadata.records }
504
+ : {})), (napi === undefined ? {} : { napi })), (wasm === undefined ? {} : { wasm })), (setsFeatureSet((_11 = context.target) === null || _11 === void 0 ? void 0 : _11.options) ? { ownFeatureSet: true } : {})), (nextest ? { testRunner: "nextest" } : {})), (testModeDecision === undefined ? {} : { testMode: testModeDecision })), { featureUnification: strategy }), (cargo.hakariPlatforms === undefined ? {} : { hakariPlatforms: cargo.hakariPlatforms })), (typeof cargo.hakariPackage === "string" ? { hakariPackage: cargo.hakariPackage } : {})), { env });
505
+ }
506
+ /**
507
+ * Whether options set a feature set other than the default features:
508
+ * features, all features or no default features (`DES-FEATURE-SETS`).
509
+ */
510
+ function setsFeatureSet(options) {
511
+ if (options === undefined) {
512
+ return false;
513
+ }
514
+ const { features, allFeatures, noDefaultFeatures } = options;
515
+ return ((Array.isArray(features) && features.length > 0) ||
516
+ (typeof features === "string" && features !== "") ||
517
+ allFeatures === true ||
518
+ noDefaultFeatures === true);
519
+ }
520
+ //# sourceMappingURL=task.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"task.js","sourceRoot":"","sources":["../../../../nx-rust/src/executors/task.ts"],"names":[],"mappings":";;;AAoIA,0BAwHC;AA6HD,kCAyWC;;AAjuBD,yCAA0C;AAC1C,yCAA8C;AAE9C,oDAAsD;AACtD,0DAA8F;AAC9F,8CAAoD;AAEpD,8CAK0B;AAC1B,4DAKiC;AACjC,yDAAuD;AACvD,uCAAyE;AACzE,uCAAwC;AACxC,iDAA+C;AAC/C,2DAA6E;AA0C3E,iGA1C6B,oCAAgB,OA0C7B;AAzClB,2CAAyC;AACzC,qCAAyD;AACzD,6CAA6E;AAC7E,6CAAiD;AACjD,mDAA0D;AAC1D,+DAA4D;AAC5D,yDAA2E;AAC3E,mCAA6C;AAC7C,6CAA8C;AAC9C,yCAAmG;AACnG,qDAAkF;AA6BhF,iGA7BO,iCAAgB,OA6BP;AA5BlB,+CAgBuB;AAgBrB,gGApBA,6BAAe,OAoBA;AACf,0FAlBA,uBAAS,OAkBA;AAhBX,iDAA4E;AAC5E,2CAMqB;AACrB,6CAA6E;AAW7E;;;;GAIG;AACH,MAAM,eAAe,GAAqC;IACxD,GAAG,EAAE,mEAAmE;IACxE,IAAI,EAAE,mHAAmH;IAC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