@edspencer/paddock 0.82.0 → 0.82.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 (107) hide show
  1. package/package.json +1 -1
  2. package/packages/server/dist/cli/args.js +2 -2
  3. package/packages/server/dist/cli/busy-command.js +1 -1
  4. package/packages/server/dist/cli/busy.js +10 -12
  5. package/packages/server/dist/cli/exit-codes.d.ts +21 -45
  6. package/packages/server/dist/cli/exit-codes.js +42 -45
  7. package/packages/server/dist/cli/output.js +5 -6
  8. package/packages/server/dist/cli/paddock.js +9 -9
  9. package/packages/server/dist/cli/service/index.d.ts +2 -2
  10. package/packages/server/dist/cli/service/index.js +30 -24
  11. package/packages/server/dist/cli/service/launchd.d.ts +31 -84
  12. package/packages/server/dist/cli/service/launchd.js +104 -304
  13. package/packages/server/dist/cli/service/logs.d.ts +9 -28
  14. package/packages/server/dist/cli/service/logs.js +33 -75
  15. package/packages/server/dist/cli/service/manager.d.ts +93 -0
  16. package/packages/server/dist/cli/service/manager.js +21 -0
  17. package/packages/server/dist/cli/service/path-env.d.ts +7 -18
  18. package/packages/server/dist/cli/service/path-env.js +30 -81
  19. package/packages/server/dist/cli/service/spec.d.ts +4 -31
  20. package/packages/server/dist/cli/service/spec.js +9 -0
  21. package/packages/server/dist/cli/service/systemd.d.ts +27 -101
  22. package/packages/server/dist/cli/service/systemd.js +106 -262
  23. package/packages/server/dist/cli/update/health.d.ts +48 -0
  24. package/packages/server/dist/cli/update/health.js +64 -0
  25. package/packages/server/dist/cli/update/install-method.d.ts +29 -76
  26. package/packages/server/dist/cli/update/install-method.js +103 -178
  27. package/packages/server/dist/cli/update/lock.d.ts +7 -12
  28. package/packages/server/dist/cli/update/lock.js +28 -62
  29. package/packages/server/dist/cli/update/package-manager.d.ts +39 -74
  30. package/packages/server/dist/cli/update/package-manager.js +95 -160
  31. package/packages/server/dist/cli/update/registry.d.ts +17 -54
  32. package/packages/server/dist/cli/update/registry.js +46 -89
  33. package/packages/server/dist/cli/update/semver.d.ts +18 -41
  34. package/packages/server/dist/cli/update/semver.js +74 -124
  35. package/packages/server/dist/cli/update/update-check.d.ts +15 -26
  36. package/packages/server/dist/cli/update/update-check.js +30 -60
  37. package/packages/server/dist/cli/update/update.d.ts +57 -91
  38. package/packages/server/dist/cli/update/update.js +230 -431
  39. package/packages/server/dist/cli/update-command.js +3 -5
  40. package/packages/server/package.json +1 -1
  41. package/packages/web/dist/assets/{DeleteProjectDialog-CphdGB3R.js → DeleteProjectDialog-CgHpQctt.js} +1 -1
  42. package/packages/web/dist/assets/DiscoverPage-CG6cf-0i.js +2 -0
  43. package/packages/web/dist/assets/{DiscoverView-B_kcF4sm.js → DiscoverView-BKqI0I1E.js} +1 -1
  44. package/packages/web/dist/assets/{InstanceConfigPage-CvUK5DKW.js → InstanceConfigPage-DL3raCK1.js} +1 -1
  45. package/packages/web/dist/assets/{MarkdownRenderer-DvZ-j_Ao.js → MarkdownRenderer-DcjEuf3s.js} +1 -1
  46. package/packages/web/dist/assets/{ProjectRedirect-DayHvUH2.js → ProjectRedirect-DerkA-nE.js} +1 -1
  47. package/packages/web/dist/assets/{ProjectView-CCw83gUi.js → ProjectView-NwfC3_w7.js} +3 -3
  48. package/packages/web/dist/assets/{ProjectsGrid-B3Klg2H4.js → ProjectsGrid-BeORa0UH.js} +1 -1
  49. package/packages/web/dist/assets/{RootHome-BxcDvpgI.js → RootHome-BYJs8qJ6.js} +1 -1
  50. package/packages/web/dist/assets/{Surfaces-7UlhFBSG.js → Surfaces-w-kEaAYU.js} +1 -1
  51. package/packages/web/dist/assets/{arc-DNkh5o5Q.js → arc-Bv56hasM.js} +1 -1
  52. package/packages/web/dist/assets/{architectureDiagram-3BPJPVTR-BrgN3oLF.js → architectureDiagram-3BPJPVTR-BHEknx9i.js} +1 -1
  53. package/packages/web/dist/assets/{blockDiagram-GPEHLZMM-D05XOJSk.js → blockDiagram-GPEHLZMM-DtxTMrPX.js} +1 -1
  54. package/packages/web/dist/assets/{c4Diagram-AAUBKEIU-CKaMBhMP.js → c4Diagram-AAUBKEIU-DRpEYOlM.js} +1 -1
  55. package/packages/web/dist/assets/channel-CdIiAqY2.js +2 -0
  56. package/packages/web/dist/assets/{chunk-2J33WTMH-8hgadCQc.js → chunk-2J33WTMH-S4s7GCg7.js} +1 -1
  57. package/packages/web/dist/assets/{chunk-4BX2VUAB-CBfEC-pu.js → chunk-4BX2VUAB-BkWVPLf1.js} +1 -1
  58. package/packages/web/dist/assets/{chunk-55IACEB6-DV1eMgHk.js → chunk-55IACEB6-4-FQp01F.js} +1 -1
  59. package/packages/web/dist/assets/{chunk-727SXJPM-Cfgl5fxY.js → chunk-727SXJPM-BeyDWdIb.js} +1 -1
  60. package/packages/web/dist/assets/{chunk-AQP2D5EJ-BXhqD295.js → chunk-AQP2D5EJ-ZSxKy745.js} +1 -1
  61. package/packages/web/dist/assets/{chunk-FMBD7UC4-TFGOPtek.js → chunk-FMBD7UC4-Bq8uV9j-.js} +1 -1
  62. package/packages/web/dist/assets/{chunk-ND2GUHAM-CHFM665R.js → chunk-ND2GUHAM-BOFsRyHk.js} +1 -1
  63. package/packages/web/dist/assets/{chunk-QZHKN3VN-CqEf6MMT.js → chunk-QZHKN3VN-uZ6oNc4m.js} +1 -1
  64. package/packages/web/dist/assets/classDiagram-4FO5ZUOK-DCCUHba0.js +2 -0
  65. package/packages/web/dist/assets/classDiagram-v2-Q7XG4LA2-DCCUHba0.js +2 -0
  66. package/packages/web/dist/assets/{core-DmEaKxBb.js → core-CYuJAM2U.js} +1 -1
  67. package/packages/web/dist/assets/{cose-bilkent-S5V4N54A-BnGI6jkr.js → cose-bilkent-S5V4N54A-DIzkVSFb.js} +1 -1
  68. package/packages/web/dist/assets/{dagre-BM42HDAG-CKoPx61E.js → dagre-BM42HDAG-CHR6jJBv.js} +1 -1
  69. package/packages/web/dist/assets/{diagram-2AECGRRQ-mMmtlBl1.js → diagram-2AECGRRQ-BAFXCH8Q.js} +1 -1
  70. package/packages/web/dist/assets/{diagram-5GNKFQAL-Cdz9Mtnt.js → diagram-5GNKFQAL-BJ5t5gbz.js} +1 -1
  71. package/packages/web/dist/assets/{diagram-KO2AKTUF-DQxM3wYj.js → diagram-KO2AKTUF-D9Xt0IVg.js} +1 -1
  72. package/packages/web/dist/assets/{diagram-LMA3HP47-BWrinPsq.js → diagram-LMA3HP47-Bq38u6sy.js} +1 -1
  73. package/packages/web/dist/assets/{diagram-OG6HWLK6-U6MYUve2.js → diagram-OG6HWLK6-CMQVqkpi.js} +1 -1
  74. package/packages/web/dist/assets/{documentTitle-DGjRXuTP.js → documentTitle-M1lrfXRU.js} +1 -1
  75. package/packages/web/dist/assets/{erDiagram-TEJ5UH35-xqMCsXxY.js → erDiagram-TEJ5UH35-C63M1g9b.js} +1 -1
  76. package/packages/web/dist/assets/{flowDiagram-I6XJVG4X-PMfy_czF.js → flowDiagram-I6XJVG4X-D3j8ACN7.js} +1 -1
  77. package/packages/web/dist/assets/{ganttDiagram-6RSMTGT7-whhYYE4N.js → ganttDiagram-6RSMTGT7-B1Fd1A2Y.js} +1 -1
  78. package/packages/web/dist/assets/{gitGraphDiagram-PVQCEYII-C51JW4tf.js → gitGraphDiagram-PVQCEYII-CEhZhDdR.js} +1 -1
  79. package/packages/web/dist/assets/{index-CHOtvlnO.js → index-1E9yHciS.js} +2 -2
  80. package/packages/web/dist/assets/{infoDiagram-5YYISTIA-SH8cr905.js → infoDiagram-5YYISTIA-Ctquaew6.js} +1 -1
  81. package/packages/web/dist/assets/{ishikawaDiagram-YF4QCWOH-BjqaoU3U.js → ishikawaDiagram-YF4QCWOH-DV4GvA1R.js} +1 -1
  82. package/packages/web/dist/assets/{journeyDiagram-JHISSGLW-CBmdEVrd.js → journeyDiagram-JHISSGLW-C_Cy9waA.js} +1 -1
  83. package/packages/web/dist/assets/{kanban-definition-UN3LZRKU-U8njjMLZ.js → kanban-definition-UN3LZRKU-CGr9ctEf.js} +1 -1
  84. package/packages/web/dist/assets/{linear-DF66GPs1.js → linear-D3U8NOkt.js} +1 -1
  85. package/packages/web/dist/assets/{mermaid.core-CouJz7Ph.js → mermaid.core-BiArdWKV.js} +4 -4
  86. package/packages/web/dist/assets/{mindmap-definition-RKZ34NQL-BYIf0oFt.js → mindmap-definition-RKZ34NQL-CZIpzj8Z.js} +1 -1
  87. package/packages/web/dist/assets/{pieDiagram-4H26LBE5-Cm8rgg09.js → pieDiagram-4H26LBE5-1MaeS3rt.js} +1 -1
  88. package/packages/web/dist/assets/{quadrantDiagram-W4KKPZXB-C3Il5kOH.js → quadrantDiagram-W4KKPZXB-B5pgQ54e.js} +1 -1
  89. package/packages/web/dist/assets/{requirementDiagram-4Y6WPE33-D3PE2nTe.js → requirementDiagram-4Y6WPE33-BNnxrpGr.js} +1 -1
  90. package/packages/web/dist/assets/{sankeyDiagram-5OEKKPKP-DdmvBM18.js → sankeyDiagram-5OEKKPKP-DsxVH-hM.js} +1 -1
  91. package/packages/web/dist/assets/{sequenceDiagram-3UESZ5HK-B8M_GAIq.js → sequenceDiagram-3UESZ5HK-Ke9LcFZI.js} +1 -1
  92. package/packages/web/dist/assets/{stateDiagram-AJRCARHV-DZkXnK1_.js → stateDiagram-AJRCARHV-UJzmflND.js} +1 -1
  93. package/packages/web/dist/assets/stateDiagram-v2-BHNVJYJU-DgUc3HkP.js +2 -0
  94. package/packages/web/dist/assets/{timeline-definition-PNZ67QCA-IHXq7rqi.js → timeline-definition-PNZ67QCA-BRjNALVI.js} +1 -1
  95. package/packages/web/dist/assets/{vennDiagram-CIIHVFJN-Dga7tLtT.js → vennDiagram-CIIHVFJN-ClMAspxz.js} +1 -1
  96. package/packages/web/dist/assets/{wardley-L42UT6IY-CmcwnEJ-.js → wardley-L42UT6IY-UPv4JEmz.js} +1 -1
  97. package/packages/web/dist/assets/{wardleyDiagram-YWT4CUSO-zHuSLrD4.js → wardleyDiagram-YWT4CUSO-BgYJbdEx.js} +1 -1
  98. package/packages/web/dist/assets/{xychartDiagram-2RQKCTM6-D93MU_ic.js → xychartDiagram-2RQKCTM6-Bfk5HjGx.js} +1 -1
  99. package/packages/web/dist/index.html +1 -1
  100. package/packages/web/dist/sw.js +1 -1
  101. package/packages/server/dist/cli/service/backend.d.ts +0 -115
  102. package/packages/server/dist/cli/service/backend.js +0 -19
  103. package/packages/web/dist/assets/DiscoverPage-C4OPLNO8.js +0 -2
  104. package/packages/web/dist/assets/channel-JrEedxB8.js +0 -2
  105. package/packages/web/dist/assets/classDiagram-4FO5ZUOK-CHJiQp-W.js +0 -2
  106. package/packages/web/dist/assets/classDiagram-v2-Q7XG4LA2-CHJiQp-W.js +0 -2
  107. package/packages/web/dist/assets/stateDiagram-v2-BHNVJYJU-CjCdT9Ls.js +0 -2
@@ -1,109 +1,88 @@
1
- import fsDefault from "node:fs";
2
- import type { Output } from "../output.js";
3
- import { type InstallInfo } from "./install-method.js";
4
- import { type RunResult, type Spawn } from "./package-manager.js";
1
+ import fsDefault from 'node:fs';
2
+ import { type HealthVerdict } from './health.js';
3
+ import { type InstallInfo } from './install-method.js';
4
+ import type { Output } from '../output.js';
5
+ import { type NpmContext, type RunResult, type Spawn } from './package-manager.js';
6
+ import { type UpdateCheck } from './update-check.js';
7
+ export type { HealthVerdict } from './health.js';
5
8
  /** SPEC §5 step 12: 30 seconds unless the tool sets its own. */
6
9
  export declare const HEALTH_TIMEOUT_MS = 30000;
10
+ /** How long to wait for the old version to stop answering after the stop (step 9). */
11
+ export declare const STOP_TIMEOUT_MS = 15000;
7
12
  /** How many log lines a failure prints (SPEC §5 step 13). */
8
13
  export declare const LOG_LINES_ON_FAILURE = 20;
9
- /** What `update` was asked to do. */
14
+ /** What `update` was asked (SPEC §1). */
10
15
  export interface UpdateOptions {
11
- /** Report and change nothing (SPEC §1). */
16
+ /** Report, and change nothing. */
12
17
  check?: boolean;
13
- /** A version or a dist-tag. The only way to move to a lower version. */
18
+ /** A version or a dist-tag: the only way to move to a lower version. */
14
19
  to?: string;
15
- /** Skip the question. Required without a TTY. */
20
+ /** Skip the question. Needed without a TTY. */
16
21
  yes?: boolean;
17
22
  /** Skip the busy check, and nothing else. */
18
23
  force?: boolean;
19
24
  json?: boolean;
20
25
  }
21
- /** What the service looks like from `update`'s point of view. */
26
+ /** The service, as `update` sees it. */
22
27
  export interface ServiceSnapshot {
23
28
  installed: boolean;
24
29
  running: boolean;
25
- /** The URL the installed unit serves, when there is one. */
30
+ /** The URL the installed unit serves, or a foreground `serve` found through `runtime.json`. */
26
31
  url?: string;
27
- /** The log file the unit names, for the failure tail. */
32
+ /** The log the unit names, for the failure's tail. */
28
33
  log?: string;
29
34
  }
30
35
  export interface UpdateServiceHooks {
31
- /** Is a unit installed, is it running, and where. */
36
+ /** Is a unit installed, is it running, and where. With no unit, report a foreground `serve` from `runtime.json`. */
32
37
  inspect(): ServiceSnapshot;
33
- /** Stop the service. Throws with the supervisor's own words on failure. */
38
+ /** Stops the service. Throws, with the service manager's own words, if it can't. */
34
39
  stop(): void;
35
- /**
36
- * `<cli> service install --refresh`, run through the NEW CLI (SPEC §5 step
37
- * 11). Returns the subprocess result so the caller can show what it said.
38
- */
40
+ /** Runs `<node> <cliPath> service install --refresh`: the new CLI on the way up, the old one on a rollback. */
39
41
  refresh(cliPath: string): RunResult;
40
- /** The last `lines` lines of the service log, or '' when there is no log. */
42
+ /** The last `lines` lines of the service's log, or ''. */
41
43
  tail(lines: number): string;
42
44
  }
43
- /** "Did the target answer?" — the three outcomes that matter (SPEC §5 step 12). */
44
- export type HealthVerdict = {
45
- state: "ok";
46
- version: string;
47
- }
48
- /** Something answers, but it is not the version we installed. */
49
- | {
50
- state: "wrong-version";
51
- version: string;
52
- } | {
53
- state: "no-answer";
54
- };
55
45
  export interface UpdateProduct {
56
46
  /** `Paddock`. */
57
47
  name: string;
58
- /** `paddock` — the bin, for `<tool>: <message>` and printed commands. */
48
+ /** `paddock`: the bin, for `<tool>: <message>` and the printed commands. */
59
49
  tool: string;
60
50
  /** `@edspencer/paddock`. */
61
51
  packageName: string;
62
- /** `PADDOCK` — gives `PADDOCK_IN_DOCKER` and `PADDOCK_UPDATE_HINT`. */
52
+ /** `PADDOCK`: gives `PADDOCK_IN_DOCKER` and `PADDOCK_UPDATE_HINT`. */
63
53
  envPrefix: string;
64
- /** The data home: `<home>/update.lock` and `<home>/update-check.json`. */
54
+ /** The data home, for `update.lock` and `update-check.json`: the one `service status` reads the cache from. */
65
55
  home: string;
66
- /** This CLI's own version, from its `package.json`. */
56
+ /** This CLI's version, from its `package.json`. */
67
57
  currentVersion: string;
68
58
  /**
69
- * `process.argv[1]` — NOT realpath'd.
70
- *
71
- * Both forms are needed and for different reasons. The unresolved path is a
72
- * bin shim, and re-resolving it AFTER the install is what finds the new CLI
73
- * under a package manager whose realpath carries the version in it (pnpm).
74
- * The realpath is what SPEC §6's table walks up from.
59
+ * `process.argv[1]`, not realpath'd. Re-resolving the bin's symlink after the install is what finds the new CLI
60
+ * under a manager that puts the version in the real path (pnpm). §6's walk-up realpaths it itself.
75
61
  */
76
62
  entry: string;
77
- /** Where the CLI sits inside the package: `packages/server/dist/cli/paddock.js`. */
63
+ /** Where the CLI sits in the package: `dist/server/cli.js`. */
78
64
  binSubpath: string;
79
- /** The container image, for the Docker notice: `ghcr.io/edspencer/paddock`. */
65
+ /** The image, for the Docker notice: `ghcr.io/edspencer/paddock`. */
80
66
  image?: string;
81
- /**
82
- * The synopsis printed after `update`'s own usage error (SPEC §2: the usage
83
- * follows the message).
84
- *
85
- * `update` has exactly one — "there is no terminal to ask, so `--yes` is
86
- * required" — and it is the command's own usage rather than the tool's,
87
- * because the reader's problem is one flag on the command they just typed.
88
- */
67
+ /** `update`'s own usage, printed after the exit-2 refusal (SPEC §2). */
89
68
  usage?: string;
90
- /** The release notes for a version. */
69
+ /** The release notes for a version: the notice's `Changes:` line. */
91
70
  changelogUrl(version: string): string;
92
71
  healthTimeoutMs?: number;
93
- /** The busy check (SPEC §5 step 6): null to go ahead, or 75 having printed why. */
72
+ /** The busy check (SPEC §5 step 6): null to go ahead, or 75 having printed why (`guardBusy` in busy-client.ts). */
94
73
  guardBusy(o: {
95
74
  force: boolean;
96
75
  home: string;
97
76
  }): Promise<number | null>;
98
77
  service: UpdateServiceHooks;
99
- /** Poll `<url>/api/health` until it reports `version`, or the budget runs out. */
100
- waitForVersion(o: {
78
+ /** Defaults to `waitForVersion` in health.ts. */
79
+ waitForVersion?(o: {
101
80
  url: string;
102
81
  version: string;
103
82
  timeoutMs: number;
104
83
  }): Promise<HealthVerdict>;
105
84
  }
106
- /** Everything that touches the world, injected so the sequence is testable. */
85
+ /** Everything that touches the machine. */
107
86
  export interface UpdateEnvironment {
108
87
  out: Output;
109
88
  env?: NodeJS.ProcessEnv;
@@ -111,50 +90,37 @@ export interface UpdateEnvironment {
111
90
  execPath?: string;
112
91
  platform?: NodeJS.Platform;
113
92
  fetch?: typeof globalThis.fetch;
114
- fs?: Pick<typeof fsDefault, "existsSync" | "readFileSync" | "realpathSync">;
115
- /** Is there a person at a keyboard? (SPEC §3.) */
93
+ fs?: Pick<typeof fsDefault, 'existsSync' | 'readFileSync' | 'realpathSync'>;
94
+ /** Is there a person at a keyboard? (SPEC §3.) Defaults to stdin and stderr both being TTYs. */
116
95
  isTTY?: boolean;
117
- /**
118
- * The Node to test the target's `engines.node` against.
119
- *
120
- * Injected so the "the target needs a newer Node" path can be proven, which
121
- * it otherwise cannot be: a test runs on whatever Node CI has, and the only
122
- * Nodes that fail a real `engines` range are ones the suite cannot run on.
123
- */
96
+ /** The Node to check the target's `engines.node` against. */
124
97
  nodeVersion?: string;
125
- /** Ask the question. Only called when {@link isTTY} and `--yes` was not given. */
98
+ /** Asks the question; only called on a TTY without `--yes`. */
126
99
  confirm?: (question: string) => Promise<boolean>;
127
- /** Injected for tests: `isWritable`. */
128
100
  writable?: (dir: string) => boolean;
101
+ /** Injected for tests: waits between the stop's health polls. */
102
+ sleep?: (ms: number) => Promise<void>;
129
103
  }
130
- /**
131
- * Run `update`, and return the exit code (SPEC §2: the caller assigns
132
- * `process.exitCode`; nothing here calls `process.exit`).
133
- */
104
+ export type UpdateOutcome = 'up-to-date' | 'ahead' | 'available' | 'updated' | 'restart-required' | 'cannot-self-update' | 'not-writable' | 'node-too-old' | 'busy' | 'needs-yes' | 'declined' | 'rolled-back' | 'needs-human' | 'failed';
105
+ /** `update --json`'s document: the check, plus what happened. `--check --json` matches the update-check schema. */
106
+ export interface UpdateDoc extends Partial<UpdateCheck> {
107
+ outcome: UpdateOutcome;
108
+ message?: string;
109
+ url?: string;
110
+ }
111
+ /** Runs `update` and returns the exit code; the caller sets `process.exitCode`. */
134
112
  export declare function runUpdate(product: UpdateProduct, opts: UpdateOptions, envp: UpdateEnvironment): Promise<number>;
135
113
  /**
136
- * Find the CLI on disk that reports `wanted`, trying the places it can be.
137
- *
138
- * Three candidates, in the order that copes with the most layouts:
114
+ * The CLI on disk that reports `wanted`, tried in this order (keep it):
139
115
  *
140
- * 1. **`realpath(argv[1])`, resolved NOW.** The bin shim is a symlink, and a
141
- * package manager that puts the version in the package's real path (pnpm's
142
- * store) repoints that symlink on install. Re-resolving it after the install
143
- * is the only candidate that follows.
144
- * 2. `<npm root -g>/<name>/<binSubpath>` — the npm-global layout, asked of npm
145
- * rather than assumed.
146
- * 3. The package root §6 found, plus the same subpath — right for every layout
147
- * whose path does not move.
116
+ * 1. `realpath(argv[1])`, resolved now: a manager whose real path carries the version (pnpm's store) repoints the
117
+ * bin's symlink on install, and only this candidate follows it;
118
+ * 2. `<npm root -g>/<name>/<binSubpath>`;
119
+ * 3. the package root §6 found, plus the same subpath.
148
120
  *
149
- * Each is run (`node <cli> --version`) and the first that reports `wanted`
150
- * wins. That is deliberately stricter than "the file exists": the thing this
151
- * guards against is handing `service install --refresh` to a CLI that is still
152
- * the old version, which would produce a green update that changed nothing.
121
+ * Each is run with `--version`, and the first that reports `wanted` wins. "The file exists" isn't enough: handing the
122
+ * refresh to a CLI that's still the old version would make a green update that changed nothing.
153
123
  */
154
- export declare function findCli(product: UpdateProduct, info: InstallInfo | undefined, wanted: string, ctx: {
155
- spawn?: Spawn;
156
- execPath?: string;
157
- platform?: NodeJS.Platform;
158
- env?: NodeJS.ProcessEnv;
159
- fs?: Pick<typeof fsDefault, "existsSync" | "readFileSync" | "realpathSync">;
124
+ export declare function findCli(product: Pick<UpdateProduct, 'entry' | 'packageName' | 'binSubpath'>, info: InstallInfo | undefined, wanted: string, ctx: NpmContext & {
125
+ fs?: Pick<typeof fsDefault, 'existsSync' | 'realpathSync'>;
160
126
  }): string | undefined;