rman 1.3.0 → 2.0.0-beta.2

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 (153) hide show
  1. package/README.md +63 -19
  2. package/cli.d.ts +5 -0
  3. package/cli.js +214 -88
  4. package/commands/build.command.d.ts +177 -3
  5. package/commands/build.command.js +20 -10
  6. package/commands/changed.command.d.ts +80 -3
  7. package/commands/changed.command.js +19 -12
  8. package/commands/changelog.command.d.ts +192 -3
  9. package/commands/changelog.command.js +87 -43
  10. package/commands/config.command.d.ts +44 -3
  11. package/commands/config.command.js +30 -19
  12. package/commands/diff.command.d.ts +37 -3
  13. package/commands/diff.command.js +25 -16
  14. package/commands/exec.command.d.ts +193 -3
  15. package/commands/exec.command.js +60 -58
  16. package/commands/github-release.command.d.ts +154 -3
  17. package/commands/github-release.command.js +67 -37
  18. package/commands/import.command.d.ts +36 -3
  19. package/commands/import.command.js +28 -20
  20. package/commands/info.command.d.ts +35 -7
  21. package/commands/info.command.js +36 -30
  22. package/commands/list.command.d.ts +163 -3
  23. package/commands/list.command.js +109 -71
  24. package/commands/publish.command.d.ts +231 -0
  25. package/commands/publish.command.js +304 -0
  26. package/commands/run.command.d.ts +186 -6
  27. package/commands/run.command.js +26 -72
  28. package/commands/test.command.d.ts +173 -3
  29. package/commands/test.command.js +16 -10
  30. package/commands/version.command.d.ts +317 -3
  31. package/commands/version.command.js +149 -69
  32. package/commands.d.ts +32 -0
  33. package/commands.js +28 -0
  34. package/constants.js +1 -1
  35. package/core/application.d.ts +116 -0
  36. package/core/application.js +143 -0
  37. package/core/command-builder.d.ts +14 -0
  38. package/core/command-builder.js +78 -0
  39. package/core/config.d.ts +140 -19
  40. package/core/config.js +258 -74
  41. package/core/core-services.d.ts +14 -0
  42. package/core/core-services.js +30 -0
  43. package/core/core-targets.d.ts +14 -0
  44. package/core/core-targets.js +16 -0
  45. package/core/custom-command.d.ts +42 -6
  46. package/core/custom-command.js +44 -17
  47. package/core/extends-config.d.ts +13 -5
  48. package/core/extends-config.js +52 -12
  49. package/core/load-config-module.d.ts +28 -0
  50. package/core/load-config-module.js +42 -0
  51. package/core/manifest.d.ts +47 -25
  52. package/core/manifest.js +51 -69
  53. package/core/merge-config.d.ts +33 -34
  54. package/core/merge-config.js +137 -92
  55. package/core/package.d.ts +145 -17
  56. package/core/package.js +128 -36
  57. package/core/plugin-loader.d.ts +65 -0
  58. package/core/plugin-loader.js +234 -0
  59. package/core/plugin.d.ts +135 -90
  60. package/core/plugin.js +70 -173
  61. package/core/publish-target.d.ts +124 -0
  62. package/core/publish-target.js +30 -0
  63. package/core/registry.d.ts +30 -0
  64. package/core/registry.js +47 -0
  65. package/core/repository.d.ts +72 -9
  66. package/core/repository.js +293 -44
  67. package/core/resolve-target.d.ts +1 -1
  68. package/core/resolve-target.js +1 -1
  69. package/core/service.d.ts +49 -0
  70. package/core/service.js +40 -0
  71. package/core/version-scheme.d.ts +23 -1
  72. package/core/version-scheme.js +29 -1
  73. package/core/workspace.d.ts +84 -33
  74. package/core/workspace.js +63 -22
  75. package/index.d.ts +111 -14
  76. package/index.js +85 -9
  77. package/interfaces/rman-config.interface.d.ts +725 -202
  78. package/interfaces/rman-config.interface.js +61 -1
  79. package/package.json +2 -1
  80. package/plugins/builtins.d.ts +44 -0
  81. package/plugins/builtins.js +33 -0
  82. package/plugins/detect.d.ts +78 -0
  83. package/plugins/detect.js +70 -0
  84. package/plugins/node/augmentation/rman.augmentation.d.ts +84 -0
  85. package/plugins/node/augmentation/rman.augmentation.js +1 -0
  86. package/plugins/node/augmentation/system-info.augmentation.d.ts +26 -0
  87. package/plugins/node/augmentation/system-info.augmentation.js +79 -0
  88. package/plugins/node/commands/ci.command.d.ts +131 -0
  89. package/plugins/node/commands/ci.command.js +59 -0
  90. package/plugins/node/commands/clean.command.d.ts +183 -0
  91. package/plugins/node/commands/clean.command.js +73 -0
  92. package/plugins/node/index.d.ts +29 -0
  93. package/plugins/node/index.js +40 -0
  94. package/plugins/node/node-config.interface.d.ts +77 -0
  95. package/plugins/node/node-config.interface.js +7 -0
  96. package/plugins/node/node-manifest.provider.d.ts +68 -0
  97. package/plugins/node/node-manifest.provider.js +125 -0
  98. package/plugins/node/node.platform.d.ts +53 -0
  99. package/plugins/node/node.platform.js +134 -0
  100. package/plugins/node/npm-publish-target.d.ts +73 -0
  101. package/plugins/node/npm-publish-target.js +96 -0
  102. package/plugins/node/services/ci.service.d.ts +47 -0
  103. package/plugins/node/services/ci.service.js +213 -0
  104. package/plugins/node/services/clean.service.d.ts +53 -0
  105. package/plugins/node/services/clean.service.js +237 -0
  106. package/plugins/node/services/publish.service.d.ts +114 -0
  107. package/plugins/node/services/publish.service.js +371 -0
  108. package/plugins/node/services/version-plan.service.d.ts +44 -0
  109. package/plugins/node/services/version-plan.service.js +58 -0
  110. package/plugins/node/utils/npm-view.d.ts +48 -0
  111. package/plugins/node/utils/npm-view.js +71 -0
  112. package/plugins/node/utils/workspace-range.d.ts +26 -0
  113. package/plugins/node/utils/workspace-range.js +28 -0
  114. package/services/change-hash.service.d.ts +2 -2
  115. package/services/change-hash.service.js +2 -2
  116. package/services/changelog.service.d.ts +62 -51
  117. package/services/changelog.service.js +14 -11
  118. package/services/docker-publish.service.d.ts +50 -29
  119. package/services/docker-publish.service.js +43 -20
  120. package/services/exec.service.d.ts +23 -12
  121. package/services/exec.service.js +14 -9
  122. package/services/github-release.service.d.ts +44 -33
  123. package/services/github-release.service.js +13 -10
  124. package/services/import.service.d.ts +25 -14
  125. package/services/import.service.js +9 -5
  126. package/services/list.service.d.ts +62 -10
  127. package/services/list.service.js +62 -15
  128. package/services/run.service.d.ts +22 -13
  129. package/services/run.service.js +262 -223
  130. package/services/version-plan.service.d.ts +27 -4
  131. package/services/version-plan.service.js +42 -15
  132. package/services/version.service.d.ts +31 -11
  133. package/services/version.service.js +29 -13
  134. package/targets/docker.target.d.ts +53 -0
  135. package/targets/docker.target.js +40 -0
  136. package/utils/bin-path.d.ts +6 -7
  137. package/utils/bin-path.js +7 -18
  138. package/utils/branch-guard.d.ts +29 -0
  139. package/utils/branch-guard.js +31 -0
  140. package/utils/exec.d.ts +10 -0
  141. package/utils/exec.js +1 -1
  142. package/utils/logger.d.ts +1 -1
  143. package/utils/logger.js +1 -1
  144. package/utils/package-filter.d.ts +127 -7
  145. package/utils/package-filter.js +197 -16
  146. package/utils/printable-config.d.ts +1 -1
  147. package/utils/printable-config.js +1 -1
  148. package/utils/run-bin.d.ts +10 -0
  149. package/utils/run-bin.js +1 -1
  150. package/utils/run-options.d.ts +97 -0
  151. package/utils/run-options.js +81 -0
  152. package/utils/version-stamp.d.ts +1 -1
  153. package/utils/version-stamp.js +1 -1
@@ -1,3 +1,173 @@
1
- import type { Argv } from 'yargs';
2
- import type { Repository } from '../core/repository.js';
3
- export declare function initCli(repository: Repository, program: Argv): void;
1
+ import { type RmanConfig } from '../interfaces/rman-config.interface.js';
2
+ declare const COMMAND: "test";
3
+ declare const config: {
4
+ parallel: {
5
+ target: "cli";
6
+ describe: string;
7
+ coerce: (v: unknown) => boolean | number | undefined;
8
+ };
9
+ bail: {
10
+ target: "cli";
11
+ describe: string;
12
+ type: "boolean";
13
+ };
14
+ topo: {
15
+ target: "cli";
16
+ describe: string;
17
+ type: "boolean";
18
+ };
19
+ progress: {
20
+ target: "cli";
21
+ describe: string;
22
+ type: "boolean";
23
+ };
24
+ changed: {
25
+ target: "cli";
26
+ alias: string;
27
+ describe: string;
28
+ type: "boolean";
29
+ };
30
+ changedSince: {
31
+ target: "cli";
32
+ cliName: string;
33
+ describe: string;
34
+ type: "string";
35
+ conflicts: string;
36
+ };
37
+ fromRoot: {
38
+ target: "cli";
39
+ cliName: string;
40
+ alias: string;
41
+ describe: string;
42
+ type: "boolean";
43
+ };
44
+ allowBranch: {
45
+ target: "cli";
46
+ cliName: string;
47
+ describe: string;
48
+ type: "string";
49
+ };
50
+ ignoreBranch: {
51
+ target: "cli";
52
+ cliName: string;
53
+ describe: string;
54
+ type: "string";
55
+ };
56
+ scope: {
57
+ target: "cli";
58
+ describe: string;
59
+ type: "string";
60
+ };
61
+ ignore: {
62
+ target: "cli";
63
+ describe: string;
64
+ type: "string";
65
+ };
66
+ platform: {
67
+ target: "cli";
68
+ describe: string;
69
+ type: "string";
70
+ };
71
+ deps: {
72
+ target: "cli";
73
+ describe: string;
74
+ type: "boolean";
75
+ };
76
+ dependents: {
77
+ target: "cli";
78
+ describe: string;
79
+ type: "boolean";
80
+ };
81
+ };
82
+ type Args = RmanConfig.ArgsOf<typeof config, typeof COMMAND>;
83
+ declare const testCommand: (app: import("../index.js").RmanApplication) => {
84
+ command: "test";
85
+ describe: string;
86
+ /** Owns nothing, for the same reason `build` does not - see there. */
87
+ configKeys: string[];
88
+ config: {
89
+ parallel: {
90
+ target: "cli";
91
+ describe: string;
92
+ coerce: (v: unknown) => boolean | number | undefined;
93
+ };
94
+ bail: {
95
+ target: "cli";
96
+ describe: string;
97
+ type: "boolean";
98
+ };
99
+ topo: {
100
+ target: "cli";
101
+ describe: string;
102
+ type: "boolean";
103
+ };
104
+ progress: {
105
+ target: "cli";
106
+ describe: string;
107
+ type: "boolean";
108
+ };
109
+ changed: {
110
+ target: "cli";
111
+ alias: string;
112
+ describe: string;
113
+ type: "boolean";
114
+ };
115
+ changedSince: {
116
+ target: "cli";
117
+ cliName: string;
118
+ describe: string;
119
+ type: "string";
120
+ conflicts: string;
121
+ };
122
+ fromRoot: {
123
+ target: "cli";
124
+ cliName: string;
125
+ alias: string;
126
+ describe: string;
127
+ type: "boolean";
128
+ };
129
+ allowBranch: {
130
+ target: "cli";
131
+ cliName: string;
132
+ describe: string;
133
+ type: "string";
134
+ };
135
+ ignoreBranch: {
136
+ target: "cli";
137
+ cliName: string;
138
+ describe: string;
139
+ type: "string";
140
+ };
141
+ scope: {
142
+ target: "cli";
143
+ describe: string;
144
+ type: "string";
145
+ };
146
+ ignore: {
147
+ target: "cli";
148
+ describe: string;
149
+ type: "string";
150
+ };
151
+ platform: {
152
+ target: "cli";
153
+ describe: string;
154
+ type: "string";
155
+ };
156
+ deps: {
157
+ target: "cli";
158
+ describe: string;
159
+ type: "boolean";
160
+ };
161
+ dependents: {
162
+ target: "cli";
163
+ describe: string;
164
+ type: "boolean";
165
+ };
166
+ };
167
+ examples: {
168
+ command: string;
169
+ description: string;
170
+ }[];
171
+ handler: (args: Args) => Promise<void>;
172
+ };
173
+ export default testCommand;
@@ -1,15 +1,21 @@
1
- import { RunService } from '../services/run.service.js';
1
+ import { registerCommand } from '../interfaces/rman-config.interface.js';
2
2
  import { assertAllowedBranch, readBranchGuardOptions } from '../utils/branch-guard.js';
3
- import { applyRunOptions, readRunOptions } from './run.command.js';
4
- export function initCli(repository, program) {
5
- program.command({
6
- command: 'test',
7
- configKeys: ['run.test'],
3
+ import { readRunOptions, runOptions } from '../utils/run-options.js';
4
+ const COMMAND = 'test';
5
+ const config = runOptions;
6
+ const testCommand = registerCommand(app => {
7
+ const repository = app.repository;
8
+ return {
9
+ command: COMMAND,
8
10
  describe: 'Alias for "run test"',
9
- builder: cmd => applyRunOptions(cmd).example('$0 test', '# Tests packages'),
11
+ /** Owns nothing, for the same reason `build` does not - see there. */
12
+ configKeys: ['run.test'],
13
+ config,
14
+ examples: [{ command: '$0 test', description: '# Tests packages' }],
10
15
  handler: async (args) => {
11
16
  await assertAllowedBranch(repository, readBranchGuardOptions(args));
12
- await RunService.runScript(repository, 'test', { ...readRunOptions(args), commandName: 'test' });
17
+ await app.getService('run').runScript('test', { ...readRunOptions(args), commandName: 'test' });
13
18
  },
14
- });
15
- }
19
+ };
20
+ });
21
+ export default testCommand;
@@ -1,3 +1,317 @@
1
- import type { Argv } from 'yargs';
2
- import type { Repository } from '../core/repository.js';
3
- export declare function initCli(repository: Repository, program: Argv): void;
1
+ import type { ConfigValue } from '../core/config.js';
2
+ import type { RunStepValue } from '../core/run-step.js';
3
+ import { type RmanConfig } from '../interfaces/rman-config.interface.js';
4
+ /**
5
+ * Hoisted out of the metadata literal so the handler can be annotated against them - see
6
+ * `RmanConfig.ArgsOf` for why an inferred `argv` and the metadata's own typo checking cannot both
7
+ * work in one signature.
8
+ *
9
+ * `as const` on the command string is load-bearing twice over: the config key is derived from it
10
+ * (`'version'`), and so are the positional names it declares.
11
+ */
12
+ declare const COMMAND: "version [bump]";
13
+ declare const config: {
14
+ interactive: {
15
+ target: "cli";
16
+ alias: string;
17
+ describe: string;
18
+ type: "boolean";
19
+ };
20
+ show: {
21
+ target: "cli";
22
+ describe: string;
23
+ type: "boolean";
24
+ conflicts: string;
25
+ };
26
+ yes: {
27
+ target: "cli";
28
+ alias: string;
29
+ describe: string;
30
+ type: "boolean";
31
+ conflicts: string;
32
+ };
33
+ ignoreDirty: {
34
+ target: "cli";
35
+ cliName: string;
36
+ describe: string;
37
+ type: "boolean";
38
+ };
39
+ push: {
40
+ target: "cli";
41
+ describe: string;
42
+ type: "boolean";
43
+ };
44
+ message: {
45
+ target: "cli";
46
+ alias: string;
47
+ describe: string;
48
+ type: "string";
49
+ };
50
+ changelog: {
51
+ target: "both";
52
+ describe: string;
53
+ type: "boolean";
54
+ };
55
+ preid: {
56
+ target: "cli";
57
+ describe: string;
58
+ type: "string";
59
+ };
60
+ /**
61
+ * Config-only, from here down: `.rmanrc "version.*"` keys with no reason to be a flag.
62
+ * `--message` is `commitMessage`'s flag and is declared above; the rest are settings a repository
63
+ * states once, not things a single run overrides.
64
+ */
65
+ commitMessage: {
66
+ target: "config";
67
+ describe: string;
68
+ type: "string";
69
+ };
70
+ releaseTagPattern: {
71
+ target: "config";
72
+ describe: string;
73
+ type: "string";
74
+ };
75
+ stampDockerfile: {
76
+ target: "config";
77
+ describe: string;
78
+ type: "boolean";
79
+ };
80
+ allowBranch: {
81
+ target: "cli";
82
+ cliName: string;
83
+ describe: string;
84
+ type: "string";
85
+ };
86
+ ignoreBranch: {
87
+ target: "cli";
88
+ cliName: string;
89
+ describe: string;
90
+ type: "string";
91
+ };
92
+ scope: {
93
+ target: "cli";
94
+ describe: string;
95
+ type: "string";
96
+ };
97
+ ignore: {
98
+ target: "cli";
99
+ describe: string;
100
+ type: "string";
101
+ };
102
+ platform: {
103
+ target: "cli";
104
+ describe: string;
105
+ type: "string";
106
+ };
107
+ deps: {
108
+ target: "cli";
109
+ describe: string;
110
+ type: "boolean";
111
+ };
112
+ dependents: {
113
+ target: "cli";
114
+ describe: string;
115
+ type: "boolean";
116
+ };
117
+ };
118
+ /**
119
+ * The rest of `version.*` - the keys an option **cannot** describe, which is the whole test for
120
+ * belonging here.
121
+ *
122
+ * A `CommandOption` says `type: 'string'` or `type: 'boolean'`. It has no way to say "a path, or
123
+ * `{ file, constant }`" or "a shell command, or a function, or a list of either" - so these four
124
+ * are written out, intersected with the derived ones by `CommandContribution`, and the key still
125
+ * has exactly one owner. Everything above that *is* expressible is declared as an option instead:
126
+ * `Extra` is the escape hatch, not the default.
127
+ *
128
+ * **It is also the one interface in the tree holding both kinds of function**, so the value/step
129
+ * split is made here by hand, key by key. `stamp` is a **value**, so it is a `ConfigValue` and may
130
+ * be written as a function evaluated while the config resolves. The three slots are **steps**: they
131
+ * already take a function and it means something else - code `version` calls when the write
132
+ * happens, with a `RunStepContext`. Wrapping one would accept a value function where a step is what
133
+ * actually runs.
134
+ *
135
+ * A new key here goes on one side or the other, and the two mistakes are not symmetric: forgetting
136
+ * `ConfigValue` on a value key is benign (it simply cannot be written as a function yet, which is
137
+ * where every key started), while putting it on a step key is not. That asymmetry is why nothing
138
+ * wraps these automatically - see `CommandConfigFromMetadata` for the half that can be, because an
139
+ * option's value is a value by construction.
140
+ */
141
+ export interface VersionExtraKeys {
142
+ /** Files whose hard-coded version is rewritten to the version being written, in the same commit
143
+ * as the bump - paths relative to the package's own directory (e.g. `["src/constants.ts"]`).
144
+ * Per-package cascaded; a listed file a package doesn't have is a silent no-op, so one `"[*]"`
145
+ * declaration covers a repo where only some packages carry one.
146
+ *
147
+ * Stamping the source, not the build output: a build-time rewrite leaves the checked-in file
148
+ * claiming a placeholder, so anything running from source reports that placeholder, git never
149
+ * records the released version, and the rewrite has to be redone on every build. */
150
+ stamp?: ConfigValue<VersionStampEntry | VersionStampEntry[]>;
151
+ /** Command(s) run at the version write itself, when the package does not declare a hook for that
152
+ * slot of its own (`version` in a Node repository's `package.json#scripts`, whatever a plugin's
153
+ * step source answers elsewhere - the package's own declaration wins, as in `run`). An array
154
+ * runs them in sequence. `${{ pkg.targetVersion }}` is bound here and in the two below, and
155
+ * nowhere else.
156
+ *
157
+ * A `RunStepFn` runs in place of a shell command - but note that `${{ pkg.targetVersion }}` is a
158
+ * *string* substitution, so a function reads the written version off `pkg` instead. */
159
+ exec?: RunStepValue | RunStepValue[];
160
+ /** Same, before the write (`preversion` in a Node repository). */
161
+ before?: RunStepValue | RunStepValue[];
162
+ /** Same, after it (`postversion` in a Node repository). */
163
+ after?: RunStepValue | RunStepValue[];
164
+ }
165
+ /** One `version.stamp` entry: a path, or a path plus the identifier to rewrite when it is not
166
+ * spelled `version`. */
167
+ export type VersionStampEntry = string | {
168
+ file: string;
169
+ constant?: string;
170
+ };
171
+ type Args = RmanConfig.ArgsOf<typeof config, typeof COMMAND>;
172
+ declare const versionCommand: (app: import("../index.js").RmanApplication) => {
173
+ /** `as const` so the config key stays derivable from it: `CommandMetadata['command']` is a
174
+ * plain `string`, so without the assertion inference widens `'version [bump]'` and there is
175
+ * nothing left to read `'version'` out of. */
176
+ command: "version [bump]";
177
+ describe: string;
178
+ /**
179
+ * Read, not owned - so they are named here rather than declared in `config`. `group` is a core
180
+ * per-package key that decides which packages move together, `changelog.*` is consulted when
181
+ * `--changelog` folds one into the bump commit, and `allowBranch`/`ignoreBranch` are repo-wide
182
+ * keys the shared branch-guard group only exposes as flags. `version` itself is not listed: it
183
+ * is this command's own key, derived from `command`.
184
+ */
185
+ configKeys: string[];
186
+ config: {
187
+ interactive: {
188
+ target: "cli";
189
+ alias: string;
190
+ describe: string;
191
+ type: "boolean";
192
+ };
193
+ show: {
194
+ target: "cli";
195
+ describe: string;
196
+ type: "boolean";
197
+ conflicts: string;
198
+ };
199
+ yes: {
200
+ target: "cli";
201
+ alias: string;
202
+ describe: string;
203
+ type: "boolean";
204
+ conflicts: string;
205
+ };
206
+ ignoreDirty: {
207
+ target: "cli";
208
+ cliName: string;
209
+ describe: string;
210
+ type: "boolean";
211
+ };
212
+ push: {
213
+ target: "cli";
214
+ describe: string;
215
+ type: "boolean";
216
+ };
217
+ message: {
218
+ target: "cli";
219
+ alias: string;
220
+ describe: string;
221
+ type: "string";
222
+ };
223
+ changelog: {
224
+ target: "both";
225
+ describe: string;
226
+ type: "boolean";
227
+ };
228
+ preid: {
229
+ target: "cli";
230
+ describe: string;
231
+ type: "string";
232
+ };
233
+ /**
234
+ * Config-only, from here down: `.rmanrc "version.*"` keys with no reason to be a flag.
235
+ * `--message` is `commitMessage`'s flag and is declared above; the rest are settings a repository
236
+ * states once, not things a single run overrides.
237
+ */
238
+ commitMessage: {
239
+ target: "config";
240
+ describe: string;
241
+ type: "string";
242
+ };
243
+ releaseTagPattern: {
244
+ target: "config";
245
+ describe: string;
246
+ type: "string";
247
+ };
248
+ stampDockerfile: {
249
+ target: "config";
250
+ describe: string;
251
+ type: "boolean";
252
+ };
253
+ allowBranch: {
254
+ target: "cli";
255
+ cliName: string;
256
+ describe: string;
257
+ type: "string";
258
+ };
259
+ ignoreBranch: {
260
+ target: "cli";
261
+ cliName: string;
262
+ describe: string;
263
+ type: "string";
264
+ };
265
+ scope: {
266
+ target: "cli";
267
+ describe: string;
268
+ type: "string";
269
+ };
270
+ ignore: {
271
+ target: "cli";
272
+ describe: string;
273
+ type: "string";
274
+ };
275
+ platform: {
276
+ target: "cli";
277
+ describe: string;
278
+ type: "string";
279
+ };
280
+ deps: {
281
+ target: "cli";
282
+ describe: string;
283
+ type: "boolean";
284
+ };
285
+ dependents: {
286
+ target: "cli";
287
+ describe: string;
288
+ type: "boolean";
289
+ };
290
+ };
291
+ examples: {
292
+ command: string;
293
+ description: string;
294
+ }[];
295
+ positionals: {
296
+ bump: {
297
+ describe: string;
298
+ type: "string";
299
+ };
300
+ };
301
+ /** Annotated rather than inferred - `RmanConfig.ArgsOf` records why, and the casts this
302
+ * replaces are the reason it is worth two hoisted declarations. */
303
+ handler: (args: Args) => Promise<void>;
304
+ };
305
+ export default versionCommand;
306
+ /**
307
+ * `version`'s own keys, on `RmanConfig` - derived from the `config` block above rather than written
308
+ * out again, so an option added there is a config key immediately and one renamed cannot leave a
309
+ * stale interface behind. Only `target: 'config'`/`'both'` options come through, so `--interactive`
310
+ * and the other CLI-only flags stay off the config type.
311
+ */
312
+ declare module '../interfaces/rman-config.interface.js' {
313
+ namespace RmanConfig {
314
+ interface CommandConfigs extends RmanConfig.CommandContribution<ReturnType<typeof versionCommand>, VersionExtraKeys> {
315
+ }
316
+ }
317
+ }