@wtf/semantic-release-maven 1.0.0 → 2.0.0

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.
package/README.md CHANGED
@@ -35,21 +35,36 @@ export default {
35
35
  }
36
36
  ```
37
37
 
38
+ Each step of semantic-release runs the step of the ecosystem of Maven, of the contract of
39
+ [`@wtf/release`](../release/README.md): its `Release` is the version of the next release, the dry
40
+ run, the logger and the folder of the run; its plan is the train's, by `planOf` of
41
+ `@wtf/release-trains/plan`, whose `own` is the plugin's selection of the modules of the train, of
42
+ `include` and `exclude`, and whose `versions` hold each module of a train at the version of its
43
+ train; its options are the plugin's, and the modules the release installs.
44
+
38
45
  - `verifyConditions` checks the options, that `ecosystems` lists `'@wtf/release-maven'`
39
46
  (`EMAVENECOSYSTEM`), and the train; reads the poms, selects the modules of the train and puts them
40
47
  in order; reads the last release of each other train, by the trains' own checks
41
- (`EDEPENDENCYNOTRAIN`, `EDEPENDENCYNORELEASE`, `ETRAINOVERLAP`); and finds the repository each
42
- module deploys to, and the variable of `lookupAuth` (`EMAVENREPOSITORY`), which a dry run only
43
- warns of. It asks the repository nothing;
44
- - `prepare` writes the version of the release into the modules of the train, the last release of
45
- each other train into its modules, and each into the parents, dependencies and plugins that name
46
- them, and reads the poms again, so a module that is not at the version of its train fails the run;
47
- - `publish` asks the repository for the pom of each module, by a `HEAD` request, then deploys each
48
+ (`EDEPENDENCYNOTRAIN`, `EDEPENDENCYNORELEASE`, `EDEPENDENCYUNSATISFIED`, `ETRAINOVERLAP`).
49
+ semantic-release decides the version after this step, so it checks none;
50
+ - `verifyRelease` runs `verify`, once the version is known, which checks it by Maven's rules
51
+ (`EMAVENVERSION`), and finds the repository each module deploys to, and the variable of
52
+ `lookupAuth` (`EMAVENREPOSITORY`), which a dry run only warns of. It asks the repository nothing;
53
+ - `prepare` runs `prepare`, which checks the version of the release by Maven's rules
54
+ (`EMAVENVERSION` of a `SNAPSHOT`, a space or a character Maven bans), writes it into the modules
55
+ of the train, the last release of each other train into its modules, and each into the parents,
56
+ dependencies and plugins that name them, and reads the poms again, so a module that is not at the
57
+ version of its train fails the run;
58
+ - `publish` runs `publish`, which asks the repository for the pom of each module, by a `HEAD` request, then deploys each
48
59
  it lacks, in the order of their dependencies, by `mvn -B -N -f <dir>/pom.xml deploy`, and skips
49
60
  each it has: a release that stopped part way is finished by running it again. A module the
50
61
  release needs to build and neither deploys nor finds on the repository, as a test kit of
51
62
  `maven.deploy.skip`, is installed first. It gives the release of the modules, named of the
52
- repository and each module.
63
+ repository and each module, and records each module for the links of the GitLab release of the
64
+ tag, which `['@wtf/semantic-release-trains', { wrap: '@semantic-release/gitlab' }]` makes: a
65
+ module of Maven Central links to its page on `central.sonatype.com`, one of a Maven registry of
66
+ GitLab to its page on GitLab, and one of another repository to its jar, of `target` of its
67
+ folder, which the link uploads to the generic package registry of the project.
53
68
 
54
69
  `mvn` runs where the release runs, Maven and a JDK with it. It reads the credentials of the
55
70
  repository from the `<server>` of its settings whose `id` is the repository's, which the job
@@ -71,7 +86,6 @@ No step commits or pushes.
71
86
  | `lookupAuth` | none | `{ header, variable }`: the header each lookup sends, its value of that variable of the environment, as `{ "header": "Job-Token", "variable": "CI_JOB_TOKEN" }` |
72
87
  | `command` | `mvn` | Maven, as it is run, as `./mvnw` |
73
88
  | `args` | none | The arguments of each deploy after its goal, as `["-s", "ci_settings.xml", "-P", "release"]` |
74
- | `system` | Node's | The system the plugin runs by, over Node's |
75
89
 
76
90
  The schema of the options is `./schema`, and `schema.json` its JSON Schema, which an editor reads.
77
91
  `./ecosystem` is the ecosystem of Maven, which a config names as
package/dist/index.d.ts CHANGED
@@ -1,17 +1,7 @@
1
- import { type Repository } from '@wtf/release-maven/repository';
2
- import type { SystemInput } from '@wtf/release-system';
1
+ import { type LookupAuth, type Repository } from '@wtf/release-maven/repository';
3
2
  import type { Trains } from '@wtf/release-trains';
4
- import type { PrepareContext, PublishContext, VerifyConditionsContext } from 'semantic-release';
5
- /**
6
- * The header a lookup of the repository sends, and the variable of the environment that holds its
7
- * value, as `{ "header": "Job-Token", "variable": "CI_JOB_TOKEN" }` of the GitLab Maven registry.
8
- */
9
- export interface LookupAuth {
10
- /** The name of the header, as `Job-Token`, `Private-Token` or `Authorization`. */
11
- readonly header: string;
12
- /** The variable of the environment that holds its value, as `CI_JOB_TOKEN`. */
13
- readonly variable: string;
14
- }
3
+ import type { PrepareContext, PublishContext, VerifyConditionsContext, VerifyReleaseContext } from 'semantic-release';
4
+ export type { LookupAuth } from '@wtf/release-maven/repository';
15
5
  /** The options of the plugin, in the config of semantic-release or at its root. */
16
6
  export interface MavenPluginOptions {
17
7
  /** Every train of the repo: the modules of each are those whose folder its paths hold. */
@@ -50,8 +40,6 @@ export interface MavenPluginOptions {
50
40
  readonly command?: string | undefined;
51
41
  /** The arguments of each deploy after its goal, as `["-s", "ci_settings.xml", "-P", "release"]`. */
52
42
  readonly args?: readonly string[] | undefined;
53
- /** The system the plugin runs by, over Node's. */
54
- readonly system?: SystemInput;
55
43
  }
56
44
  /** The release the plugin gives semantic-release of the modules deployed. */
57
45
  export interface MavenRelease {
@@ -63,50 +51,62 @@ type OfRun = {
63
51
  readonly cwd: string;
64
52
  };
65
53
  /**
66
- * Asks the repository at `url` whether it has the pom there, by a `HEAD` of `fetch` of the headers
67
- * `headers`, which no error names.
54
+ * Asks the repository at `url` whether it has the pom there, by a `HEAD` of Node's `fetch` of the
55
+ * headers `headers`, which no error names (`lookupPom` of `@wtf/release-maven/repository`).
68
56
  *
69
57
  * @param url - The URL of the pom.
70
58
  * @param headers - The headers of the request, as of `lookupAuth`.
71
59
  * @returns Whether the repository has it: a 2xx yes, a 404 no.
72
60
  * @throws `EMAVENREPOSITORY` of a repository that cannot be reached, or answers of anything else.
73
61
  */
74
- export declare function pomLookup(url: string, headers?: Readonly<Record<string, string>>): Promise<boolean>;
62
+ export declare const pomLookup: (url: string, headers?: Readonly<Record<string, string>>) => Promise<boolean>;
75
63
  /**
76
64
  * Checks the options of the plugin, by `mavenSchema` of `./schema` (`EOPTIONS`), that `ecosystems`
77
65
  * lists `@wtf/semantic-release-maven/ecosystem` or `@wtf/release-maven` (`EMAVENECOSYSTEM`), and the
78
66
  * train of the run (`ETRAINNOTSELECTED`, `ETRAINUNKNOWN`); that the poms read, and the modules of the
79
67
  * release select and order: `EMAVENPOM`, `EMAVENARTIFACTS`, `EMAVENPRIVATE`, `EMAVENORDER`; that no
80
68
  * module is of two trains (`ETRAINOVERLAP`), and each module of another train the modules of the
81
- * train depend on has a release, by the trains' own checks (`EDEPENDENCYNOTRAIN`,
82
- * `EDEPENDENCYNORELEASE`); that each module has a repository to deploy to, of `repository` or of its
83
- * pom, but of a `lookup` and no `repository`, and that the variable of `lookupAuth` is in the
84
- * environment (`EMAVENREPOSITORY`), which a dry run only warns of. It asks the repository nothing.
69
+ * train depend on has a release that satisfies it, by the trains' own checks
70
+ * (`EDEPENDENCYNOTRAIN`, `EDEPENDENCYNORELEASE`, `EDEPENDENCYUNSATISFIED`). It checks no version
71
+ * and no repository: `verifyRelease` does, once the version is known.
85
72
  *
86
73
  * @param pluginConfig - The plugin's options of the config, with `trains` of its root.
87
74
  * @param context - The context of semantic-release's `verifyConditions` step: the folder, the
88
75
  * environment and the logger of the run.
89
76
  */
90
- export declare function verifyConditions(pluginConfig: MavenPluginOptions, context: VerifyConditionsContext & OfRun): Promise<void>;
77
+ export declare const verifyConditions: (pluginConfig: MavenPluginOptions, context: VerifyConditionsContext & OfRun) => Promise<void>;
78
+ /**
79
+ * Runs `verify` of the ecosystem, once semantic-release knows the version of the release: that the
80
+ * version is one Maven releases (`EMAVENVERSION`), and that each module has a repository to deploy
81
+ * to, of `repository` or of its pom, but of a `lookup` and no `repository`, and that the variable
82
+ * of `lookupAuth` is in the environment (`EMAVENREPOSITORY`), which a dry run only warns of. It asks
83
+ * the repository nothing. What it says and throws names the train.
84
+ *
85
+ * @param pluginConfig - The plugin's options of the config, with `trains` of its root.
86
+ * @param context - The context of semantic-release's `verifyRelease` step: the folder, the
87
+ * environment and the logger of the run, and the next release.
88
+ */
89
+ export declare const verifyRelease: (pluginConfig: MavenPluginOptions, context: VerifyReleaseContext & OfRun) => Promise<void>;
91
90
  /**
92
- * Writes the version of the release into the poms of the train, and the last release of each other
93
- * train into its poms, and each into the parents, dependencies and plugins that name them; and reads
94
- * the poms again: a module that is not at the version of its train, as one whose version is of a
95
- * property, fails the run here, before the tag's release.
91
+ * Runs `prepare` of the ecosystem: writes the version of the release into the poms of the train,
92
+ * and the last release of each other train into its poms, and each into the parents, dependencies
93
+ * and plugins that name them; and reads the poms again: a module that is not at the version of its
94
+ * train, as one whose version is of a property, fails the run here, before the tag's release.
96
95
  *
97
96
  * @param pluginConfig - The plugin's options of the config, with `trains` of its root.
98
97
  * @param context - The context of semantic-release's `prepare` step: the folder, the environment
99
98
  * and the logger of the run, and the next release.
100
- * @throws `EDEPENDENCYNOTRAIN` and `EDEPENDENCYNORELEASE` of a dependency on a module of no release,
101
- * `EMAVENSTAMP` of a pom that cannot be stamped, `EMAVENVERSION` of a module at another version after
102
- * the stamp.
99
+ * @throws `EDEPENDENCYNOTRAIN`, `EDEPENDENCYNORELEASE` and `EDEPENDENCYUNSATISFIED` of a dependency
100
+ * on a module of no release, `EMAVENSTAMP` of a pom that cannot be stamped, `EMAVENVERSION` of a
101
+ * version Maven does not release, or of a module at another version after the stamp.
103
102
  */
104
- export declare function prepare(pluginConfig: MavenPluginOptions, context: PrepareContext & OfRun): Promise<void>;
103
+ export declare const prepare: (pluginConfig: MavenPluginOptions, context: PrepareContext & OfRun) => Promise<void>;
105
104
  /**
106
- * Deploys each module of the release the repository lacks, in the order of their dependencies, at
107
- * the version of the release; each the repository has already is skipped. A module the release
108
- * needs to build and neither deploys nor finds served, as a test kit of `maven.deploy.skip`, is
109
- * installed before it (`installsOf` of `@wtf/release-maven/artifacts`).
105
+ * Runs `publish` of the ecosystem: deploys each module of the release the repository lacks, in the
106
+ * order of their dependencies, at the version of the release; each the repository has already is
107
+ * skipped. A module the release needs to build and neither deploys nor finds served, as a test kit
108
+ * of `maven.deploy.skip`, is installed before it (`installsOf` of `@wtf/release-maven/artifacts`).
109
+ * Then it records each module deployed or skipped for the links of the release of the host.
110
110
  *
111
111
  * @param pluginConfig - The plugin's options of the config, with `trains` of its root.
112
112
  * @param context - The context of semantic-release's `publish` step: the folder, the environment
@@ -116,11 +116,12 @@ export declare function prepare(pluginConfig: MavenPluginOptions, context: Prepa
116
116
  * @throws `EMAVENVERSION` of a module not at the version, `EMAVENREPOSITORY` of a repository that
117
117
  * cannot be asked, `EMAVENDEPLOY` of a deploy mvn fails.
118
118
  */
119
- export declare function publish(pluginConfig: MavenPluginOptions, context: PublishContext & OfRun): Promise<MavenRelease | false>;
119
+ export declare const publish: (pluginConfig: MavenPluginOptions, context: PublishContext & OfRun) => Promise<MavenRelease | false>;
120
120
  declare const _default: {
121
- verifyConditions: typeof verifyConditions;
122
- prepare: typeof prepare;
123
- publish: typeof publish;
121
+ verifyConditions: (pluginConfig: MavenPluginOptions, context: VerifyConditionsContext & OfRun) => Promise<void>;
122
+ verifyRelease: (pluginConfig: MavenPluginOptions, context: VerifyReleaseContext & OfRun) => Promise<void>;
123
+ prepare: (pluginConfig: MavenPluginOptions, context: PrepareContext & OfRun) => Promise<void>;
124
+ publish: (pluginConfig: MavenPluginOptions, context: PublishContext & OfRun) => Promise<MavenRelease | false>;
124
125
  };
125
126
  export default _default;
126
127
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAgEA,OAAO,EAAiC,KAAK,UAAU,EAAE,MAAM,+BAA+B,CAAA;AAE9F,OAAO,KAAK,EAAU,WAAW,EAAE,MAAM,qBAAqB,CAAA;AAI9D,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAA;AAGjD,OAAO,KAAK,EAAE,cAAc,EAAE,cAAc,EAAE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EAAE,kBAAkB,EAChC,OAAO,EAAE,oBAAoB,GAAG,KAAK,KAClC,OAAO,CAAC,IAAI,CAQf,CAAA;AAEF;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,OAAO,EAAE,CACpB,YAAY,EAAE,kBAAkB,EAChC,OAAO,EAAE,cAAc,GAAG,KAAK,KAC5B,OAAO,CAAC,IAAI,CAaf,CAAA;AAEF;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,OAAO,EAAE,CACpB,YAAY,EAAE,kBAAkB,EAChC,OAAO,EAAE,cAAc,GAAG,KAAK,KAC5B,OAAO,CAAC,YAAY,GAAG,KAAK,CAgC/B,CAAA;;qCAtHc,kBAAkB,WACvB,uBAAuB,GAAG,KAAK,KACrC,OAAO,CAAC,IAAI,CAAC;kCAuBF,kBAAkB,WACvB,oBAAoB,GAAG,KAAK,KAClC,OAAO,CAAC,IAAI,CAAC;4BAwBF,kBAAkB,WACvB,cAAc,GAAG,KAAK,KAC5B,OAAO,CAAC,IAAI,CAAC;4BA+BF,kBAAkB,WACvB,cAAc,GAAG,KAAK,KAC5B,OAAO,CAAC,YAAY,GAAG,KAAK,CAAC;;AA2ClC,wBAAoE"}
package/dist/index.js CHANGED
@@ -1,50 +1,59 @@
1
1
  import { installsOf, publishOrder, readModules, selectArtifacts } from '@wtf/release-maven/artifacts';
2
2
  import { mavenEcosystem } from '@wtf/release-maven/ecosystem';
3
3
  import { MavenError } from '@wtf/release-maven/errors';
4
- import { deployModules } from '@wtf/release-maven/publish';
5
- import { deployTargets, hasPom, pomUrl } from '@wtf/release-maven/repository';
6
- import { checkVersions, stampModules } from '@wtf/release-maven/stamp';
7
- import { throwAll } from '@wtf/release-system/errors';
8
- import { systemOf } from '@wtf/release-system/node';
9
- import { errorsOf } from '@wtf/release-system/validator';
10
- import { ownersOf, releasedVersions } from '@wtf/release-trains/packages';
4
+ import { lookupPom, releaseTargets } from '@wtf/release-maven/repository';
5
+ import { throwAll } from '@wtf/release/errors';
6
+ import { errorsOf } from '@wtf/release/validator';
7
+ import { recordReleased } from '@wtf/semantic-release/links';
8
+ import { ownersOf } from '@wtf/release-trains/packages';
9
+ import { planOf } from '@wtf/release-trains/plan';
11
10
  import { selectTrain, trainOfRun } from '@wtf/release-trains/trains';
11
+ import { runOf } from '@wtf/semantic-release';
12
+ import { markedStep } from '@wtf/semantic-release/errors';
13
+ import { inTrain, stepRelease } from '@wtf/semantic-release/release';
12
14
  import { mavenSchema } from "./schema.js";
13
- /** The system of the run, over Node's, its train, its modules, and those the release deploys. */
14
- async function releaseOf(pluginConfig, context) {
15
- const system = systemOf({ cwd: context.cwd, env: context.env, ...pluginConfig.system });
15
+ /**
16
+ * The run of a step, on Node's platform: its train, its modules, and those the release deploys, of
17
+ * `include` and `exclude`.
18
+ */
19
+ async function runOfStep(pluginConfig, context) {
20
+ const { root, platform } = await runOf(context);
16
21
  const [train] = selectTrain(pluginConfig.trains, trainOfRun(pluginConfig.train, context.env));
17
- const modules = await readModules({ cwd: context.cwd, env: context.env, system });
22
+ const modules = await readModules({ root, platform });
18
23
  const owners = ownersOf(pluginConfig.trains, modules);
19
24
  const own = new Set([...owners].filter(([, owner]) => owner === train).map(([name]) => name));
20
25
  const { include, exclude } = pluginConfig;
21
26
  const selected = publishOrder(selectArtifacts(modules, { train: own, include, exclude }));
22
- return { system, train, modules, owners, own, selected };
27
+ return { root, platform, train, modules, owners, selected };
23
28
  }
24
29
  /**
25
- * The version each module takes, by its name: of a module of the train, `version`, the release's;
26
- * of a module of another train that has released, the last release of that train, read of its tags
27
- * that `HEAD` holds (`releasedVersions` of `@wtf/release-trains/packages`), which throws
28
- * `EDEPENDENCYNOTRAIN` and `EDEPENDENCYNORELEASE` of a module of the train that depends on a module
29
- * that has none. A module of no train, or of a train of no release, takes none.
30
+ * The plan of the run, of `version`: its `own`, the modules the release deploys; and its
31
+ * `versions`, the version of each module of a train, a module of a train that does not deploy, as a
32
+ * test kit of `maven.deploy.skip`, among them, by `planOf` of `@wtf/release-trains/plan`, which reads
33
+ * the last release of each other train of its tags that `HEAD` holds, and throws
34
+ * `EDEPENDENCYNOTRAIN`, `EDEPENDENCYNORELEASE` and `EDEPENDENCYUNSATISFIED` of a module of the train
35
+ * that depends on a module of none. A module of no train, or of a train of no release, takes none;
36
+ * of no version, as before semantic-release knows it, the modules of the train take none, and the
37
+ * checks are the same.
30
38
  */
31
- async function versionsOf(pluginConfig, release, context, version) {
32
- const released = await releasedVersions({
39
+ async function planOfRun(pluginConfig, run, version) {
40
+ const plans = await planOf({
33
41
  trains: pluginConfig.trains,
34
- train: release.train,
35
- repo: [{ ecosystem: mavenEcosystem, packages: release.modules }],
36
- cwd: context.cwd,
37
- env: context.env,
38
- system: release.system
42
+ train: run.train,
43
+ version,
44
+ repo: [{ ecosystem: mavenEcosystem, packages: run.modules }],
45
+ root: run.root,
46
+ platform: run.platform
39
47
  });
40
- const versions = new Map();
41
- for (const [name, owner] of release.owners) {
42
- const of = owner === release.train ? version : released.get(owner);
43
- if (of !== undefined)
44
- versions.set(name, of);
45
- }
46
- return versions;
48
+ return { own: run.selected, versions: plans.get(mavenEcosystem.name)?.versions ?? new Map() };
47
49
  }
50
+ /**
51
+ * The release of a step of `run`, of `version`, on the contract: each line it says and each error
52
+ * of it named by the train.
53
+ */
54
+ const releaseOf = (run, context, version) => stepRelease(context, { root: run.root, platform: run.platform, train: run.train, version });
55
+ /** The options of the ecosystem of Maven, of the plugin's. */
56
+ const optionsOf = ({ repository, lookup, lookupAuth, command, args }, installs) => ({ repository, lookup, lookupAuth, command, args, installs });
48
57
  /**
49
58
  * The modules of the ecosystem of Maven, as `ecosystems` of a config names it: this plugin's
50
59
  * `./ecosystem` first, which a global install finds beside the plugin, then `@wtf/release-maven`,
@@ -58,62 +67,25 @@ function checkOptions(pluginConfig) {
58
67
  if (!MAVEN_ECOSYSTEMS.some((each) => pluginConfig.ecosystems.includes(each)))
59
68
  throw new MavenError('EMAVENECOSYSTEM', `The \`ecosystems\` of the config, ${JSON.stringify(pluginConfig.ecosystems)}, lists no ${MAVEN_ECOSYSTEMS.map((each) => `'${each}'`).join(' nor ')}: the trains read no module, so they neither order, check nor cascade the modules this plugin deploys.`, `Add '${module}' to \`ecosystems\` at the root of the config, as \`ecosystems: [${[...pluginConfig.ecosystems, module].map((each) => `'${each}'`).join(', ')}]\`.`);
60
69
  }
61
- /** Whether semantic-release runs without publishing: its option `dryRun`. */
62
- const isDryRun = (context) => context.options?.dryRun === true;
63
70
  /**
64
- * The value of the header of `lookupAuth`, of the environment: `undefined` of no `lookupAuth`.
65
- *
66
- * @throws `EMAVENREPOSITORY` of a variable the environment does not hold, or holds empty.
67
- */
68
- function lookupHeaders(lookupAuth, env) {
69
- if (lookupAuth === undefined)
70
- return undefined;
71
- const value = env[lookupAuth.variable];
72
- if (value === undefined || value === '')
73
- throw new MavenError('EMAVENREPOSITORY', `The variable ${lookupAuth.variable} of \`lookupAuth\` is not in the environment.`, `Set ${lookupAuth.variable} in the environment of the job: the plugin sends it as the header ${lookupAuth.header} of each lookup of the repository.`);
74
- return { [lookupAuth.header]: value };
75
- }
76
- /**
77
- * Asks the repository at `url` whether it has the pom there, by a `HEAD` of `fetch` of the headers
78
- * `headers`, which no error names.
71
+ * Asks the repository at `url` whether it has the pom there, by a `HEAD` of Node's `fetch` of the
72
+ * headers `headers`, which no error names (`lookupPom` of `@wtf/release-maven/repository`).
79
73
  *
80
74
  * @param url - The URL of the pom.
81
75
  * @param headers - The headers of the request, as of `lookupAuth`.
82
76
  * @returns Whether the repository has it: a 2xx yes, a 404 no.
83
77
  * @throws `EMAVENREPOSITORY` of a repository that cannot be reached, or answers of anything else.
84
78
  */
85
- export async function pomLookup(url, headers = {}) {
86
- let response;
87
- try {
88
- response = await fetch(url, {
89
- method: 'HEAD',
90
- headers: { 'cache-control': 'no-cache', ...headers }
91
- });
92
- }
93
- catch (error) {
94
- throw new MavenError('EMAVENREPOSITORY', `The repository cannot be asked for ${url}: ${error.message}`, 'Check the network of the run, the repository of the module, or the `lookup` option.');
95
- }
96
- return hasPom(response.status, url);
97
- }
98
- /**
99
- * The repository each module of the release deploys to, by its name (`deployTargets` of
100
- * `@wtf/release-maven/repository`): of `repository`, or of each pom's `distributionManagement`.
101
- * Of a `lookup` and no `repository`, none is required, and none is given: Maven deploys as the poms
102
- * say, as by the `central-publishing-maven-plugin` of Maven Central, which needs no
103
- * `distributionManagement`.
104
- */
105
- const targetsOf = (pluginConfig, selected, env) => pluginConfig.lookup !== undefined && pluginConfig.repository === undefined
106
- ? new Map()
107
- : deployTargets(selected, pluginConfig.repository, env);
79
+ export const pomLookup = (url, headers = {}) => lookupPom((input, init) => fetch(input, init), url, headers);
108
80
  /**
109
81
  * Whether the train of the run has no module to deploy, as a train of npm packages alone of a repo
110
82
  * of several ecosystems, said in the log: each step of the plugin then does nothing, and needs no
111
83
  * repository.
112
84
  */
113
- function nothingOf(release, context) {
114
- if (release.selected.length > 0)
85
+ function nothingOf(run, context) {
86
+ if (run.selected.length > 0)
115
87
  return false;
116
- context.logger.log(`Train ${release.train} has no Maven module to deploy: nothing to do.`);
88
+ context.logger.log(`Train ${run.train} has no Maven module to deploy: nothing to do.`);
117
89
  return true;
118
90
  }
119
91
  /**
@@ -122,61 +94,76 @@ function nothingOf(release, context) {
122
94
  * train of the run (`ETRAINNOTSELECTED`, `ETRAINUNKNOWN`); that the poms read, and the modules of the
123
95
  * release select and order: `EMAVENPOM`, `EMAVENARTIFACTS`, `EMAVENPRIVATE`, `EMAVENORDER`; that no
124
96
  * module is of two trains (`ETRAINOVERLAP`), and each module of another train the modules of the
125
- * train depend on has a release, by the trains' own checks (`EDEPENDENCYNOTRAIN`,
126
- * `EDEPENDENCYNORELEASE`); that each module has a repository to deploy to, of `repository` or of its
127
- * pom, but of a `lookup` and no `repository`, and that the variable of `lookupAuth` is in the
128
- * environment (`EMAVENREPOSITORY`), which a dry run only warns of. It asks the repository nothing.
97
+ * train depend on has a release that satisfies it, by the trains' own checks
98
+ * (`EDEPENDENCYNOTRAIN`, `EDEPENDENCYNORELEASE`, `EDEPENDENCYUNSATISFIED`). It checks no version
99
+ * and no repository: `verifyRelease` does, once the version is known.
129
100
  *
130
101
  * @param pluginConfig - The plugin's options of the config, with `trains` of its root.
131
102
  * @param context - The context of semantic-release's `verifyConditions` step: the folder, the
132
103
  * environment and the logger of the run.
133
104
  */
134
- export async function verifyConditions(pluginConfig, context) {
105
+ export const verifyConditions = markedStep(async (pluginConfig, context) => {
135
106
  checkOptions(pluginConfig);
136
- const release = await releaseOf(pluginConfig, context);
137
- if (nothingOf(release, context))
107
+ const run = await runOfStep(pluginConfig, context);
108
+ if (nothingOf(run, context))
138
109
  return;
139
- await versionsOf(pluginConfig, release, context, undefined);
140
- context.logger.log(`Train ${release.train} deploys ${release.selected.map(({ name }) => name).join(', ')}.`);
141
- try {
142
- targetsOf(pluginConfig, release.selected, context.env);
143
- lookupHeaders(pluginConfig.lookupAuth, context.env);
144
- }
145
- catch (error) {
146
- if (!isDryRun(context))
147
- throw error;
148
- context.logger.warn(`${error.message} A dry run deploys nothing.`);
149
- }
150
- }
110
+ // The trains' checks of the plan, of no version yet.
111
+ await planOfRun(pluginConfig, run, undefined);
112
+ context.logger.log(`Train ${run.train} deploys ${run.selected.map(({ name }) => name).join(', ')}.`);
113
+ });
151
114
  /**
152
- * Writes the version of the release into the poms of the train, and the last release of each other
153
- * train into its poms, and each into the parents, dependencies and plugins that name them; and reads
154
- * the poms again: a module that is not at the version of its train, as one whose version is of a
155
- * property, fails the run here, before the tag's release.
115
+ * Runs `verify` of the ecosystem, once semantic-release knows the version of the release: that the
116
+ * version is one Maven releases (`EMAVENVERSION`), and that each module has a repository to deploy
117
+ * to, of `repository` or of its pom, but of a `lookup` and no `repository`, and that the variable
118
+ * of `lookupAuth` is in the environment (`EMAVENREPOSITORY`), which a dry run only warns of. It asks
119
+ * the repository nothing. What it says and throws names the train.
120
+ *
121
+ * @param pluginConfig - The plugin's options of the config, with `trains` of its root.
122
+ * @param context - The context of semantic-release's `verifyRelease` step: the folder, the
123
+ * environment and the logger of the run, and the next release.
124
+ */
125
+ export const verifyRelease = markedStep(async (pluginConfig, context) => {
126
+ const { version } = context.nextRelease;
127
+ const run = await runOfStep(pluginConfig, context);
128
+ if (nothingOf(run, context))
129
+ return;
130
+ await inTrain(run.train, async () => {
131
+ const plan = await planOfRun(pluginConfig, run, version);
132
+ await mavenEcosystem.verify(releaseOf(run, context, version), plan, optionsOf(pluginConfig));
133
+ });
134
+ });
135
+ /**
136
+ * Runs `prepare` of the ecosystem: writes the version of the release into the poms of the train,
137
+ * and the last release of each other train into its poms, and each into the parents, dependencies
138
+ * and plugins that name them; and reads the poms again: a module that is not at the version of its
139
+ * train, as one whose version is of a property, fails the run here, before the tag's release.
156
140
  *
157
141
  * @param pluginConfig - The plugin's options of the config, with `trains` of its root.
158
142
  * @param context - The context of semantic-release's `prepare` step: the folder, the environment
159
143
  * and the logger of the run, and the next release.
160
- * @throws `EDEPENDENCYNOTRAIN` and `EDEPENDENCYNORELEASE` of a dependency on a module of no release,
161
- * `EMAVENSTAMP` of a pom that cannot be stamped, `EMAVENVERSION` of a module at another version after
162
- * the stamp.
144
+ * @throws `EDEPENDENCYNOTRAIN`, `EDEPENDENCYNORELEASE` and `EDEPENDENCYUNSATISFIED` of a dependency
145
+ * on a module of no release, `EMAVENSTAMP` of a pom that cannot be stamped, `EMAVENVERSION` of a
146
+ * version Maven does not release, or of a module at another version after the stamp.
163
147
  */
164
- export async function prepare(pluginConfig, context) {
148
+ export const prepare = markedStep(async (pluginConfig, context) => {
165
149
  const { version } = context.nextRelease;
166
- const release = await releaseOf(pluginConfig, context);
167
- if (nothingOf(release, context))
150
+ const run = await runOfStep(pluginConfig, context);
151
+ if (nothingOf(run, context))
168
152
  return;
169
- const versions = await versionsOf(pluginConfig, release, context, version);
170
- const done = await stampModules(release.system, context.cwd, release.modules, versions);
171
- context.logger.log(`Stamped ${version} of train ${release.train}, and ${versions.size - release.own.size} module(s) of other trains at their last release, into ${done.files.length} pom(s).`);
172
- const again = await readModules({ cwd: context.cwd, env: context.env, system: release.system });
173
- checkVersions(again, versions);
174
- }
153
+ await inTrain(run.train, async () => {
154
+ const plan = await planOfRun(pluginConfig, run, version);
155
+ const release = releaseOf(run, context, version);
156
+ const files = await mavenEcosystem.prepare(release, plan, optionsOf(pluginConfig));
157
+ const others = [...plan.versions.keys()].filter((name) => run.owners.get(name) !== run.train);
158
+ release.log(`Stamped ${version} of train ${run.train}, and ${others.length} module(s) of other trains at their last release, into ${files.length} pom(s).`);
159
+ });
160
+ });
175
161
  /**
176
- * Deploys each module of the release the repository lacks, in the order of their dependencies, at
177
- * the version of the release; each the repository has already is skipped. A module the release
178
- * needs to build and neither deploys nor finds served, as a test kit of `maven.deploy.skip`, is
179
- * installed before it (`installsOf` of `@wtf/release-maven/artifacts`).
162
+ * Runs `publish` of the ecosystem: deploys each module of the release the repository lacks, in the
163
+ * order of their dependencies, at the version of the release; each the repository has already is
164
+ * skipped. A module the release needs to build and neither deploys nor finds served, as a test kit
165
+ * of `maven.deploy.skip`, is installed before it (`installsOf` of `@wtf/release-maven/artifacts`).
166
+ * Then it records each module deployed or skipped for the links of the release of the host.
180
167
  *
181
168
  * @param pluginConfig - The plugin's options of the config, with `trains` of its root.
182
169
  * @param context - The context of semantic-release's `publish` step: the folder, the environment
@@ -186,42 +173,34 @@ export async function prepare(pluginConfig, context) {
186
173
  * @throws `EMAVENVERSION` of a module not at the version, `EMAVENREPOSITORY` of a repository that
187
174
  * cannot be asked, `EMAVENDEPLOY` of a deploy mvn fails.
188
175
  */
189
- export async function publish(pluginConfig, context) {
176
+ export const publish = markedStep(async (pluginConfig, context) => {
190
177
  const { version } = context.nextRelease;
191
- const release = await releaseOf(pluginConfig, context);
192
- if (nothingOf(release, context))
178
+ const run = await runOfStep(pluginConfig, context);
179
+ const record = { cwd: context.cwd, train: run.train, version };
180
+ if (nothingOf(run, context)) {
181
+ recordReleased(record, 'maven', []);
193
182
  return false;
194
- const { system, selected, modules } = release;
195
- checkVersions(selected, new Map(selected.map(({ name }) => [name, version])));
196
- const served = new Set((await versionsOf(pluginConfig, release, context, undefined)).keys());
197
- const installs = installsOf(modules, selected, served);
198
- const targets = targetsOf(pluginConfig, selected, context.env);
199
- const headers = lookupHeaders(pluginConfig.lookupAuth, context.env);
200
- const [first] = selected;
201
- const repository = pluginConfig.repository === undefined || first === undefined
202
- ? undefined
203
- : targets.get(first.name);
204
- const done = await deployModules({
205
- system,
206
- cwd: context.cwd,
207
- modules: publishOrder([...selected, ...installs]),
208
- installs: new Set(installs.map(({ name }) => name)),
209
- version,
210
- lookup: ({ name, groupId, artifactId }, at) => pomLookup(pomUrl(pluginConfig.lookup ?? targets.get(name)?.url ?? '', groupId, artifactId, at), headers),
211
- command: pluginConfig.command,
212
- args: pluginConfig.args,
213
- repository,
214
- log: (line) => context.logger.log(line)
183
+ }
184
+ return inTrain(run.train, async () => {
185
+ const plan = await planOfRun(pluginConfig, run, version);
186
+ // Served: each module of another train that has released, at its last release.
187
+ const served = new Set([...plan.versions.keys()].filter((name) => run.owners.get(name) !== run.train));
188
+ const installs = installsOf(run.modules, run.selected, served).map(({ name }) => name);
189
+ const released = await mavenEcosystem.publish(releaseOf(run, context, version), plan, optionsOf(pluginConfig, installs));
190
+ recordReleased(record, 'maven', released);
191
+ const [first] = run.selected;
192
+ const target = first === undefined
193
+ ? undefined
194
+ : releaseTargets([first], pluginConfig, context.env).get(first.name);
195
+ return releaseOfDeployed(released, target?.id ??
196
+ (pluginConfig.lookup === undefined ? 'Maven' : new URL(pluginConfig.lookup).host));
215
197
  });
216
- const target = first === undefined ? undefined : targets.get(first.name);
217
- return releaseOfDeployed(done, target?.id ?? (pluginConfig.lookup === undefined ? 'Maven' : new URL(pluginConfig.lookup).host));
218
- }
198
+ });
219
199
  /** The release semantic-release is given of the modules: none of no module deployed or skipped. */
220
- function releaseOfDeployed(modules, repository) {
221
- const released = modules.filter(({ status }) => status !== 'installed');
200
+ function releaseOfDeployed(released, repository) {
222
201
  if (released.length === 0)
223
202
  return false;
224
203
  return { name: `${repository} (${released.map(({ name }) => name).join(', ')})` };
225
204
  }
226
- export default { verifyConditions, prepare, publish };
205
+ export default { verifyConditions, verifyRelease, prepare, publish };
227
206
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAuDA,OAAO,EACL,UAAU,EACV,YAAY,EACZ,WAAW,EACX,eAAe,EAChB,MAAM,8BAA8B,CAAA;AACrC,OAAO,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAA;AAC7D,OAAO,EAAE,UAAU,EAAE,MAAM,2BAA2B,CAAA;AACtD,OAAO,EAAuB,aAAa,EAAE,MAAM,4BAA4B,CAAA;AAC/E,OAAO,EAAE,aAAa,EAAE,MAAM,EAAE,MAAM,EAAmB,MAAM,+BAA+B,CAAA;AAC9F,OAAO,EAAE,aAAa,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAA;AAEtE,OAAO,EAAE,QAAQ,EAAE,MAAM,4BAA4B,CAAA;AACrD,OAAO,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAA;AACnD,OAAO,EAAE,QAAQ,EAAE,MAAM,+BAA+B,CAAA;AAExD,OAAO,EAAE,QAAQ,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAA;AACzE,OAAO,EAAE,WAAW,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAA;AAGpE,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAA;AAoFzC,iGAAiG;AACjG,KAAK,UAAU,SAAS,CACtB,YAAgC,EAChC,OAAsC;IAEtC,MAAM,MAAM,GAAG,QAAQ,CAAC,EAAE,GAAG,EAAE,OAAO,CAAC,GAAG,EAAE,GAAG,EAAE,OAAO,CAAC,GAAG,EAAE,GAAG,YAAY,CAAC,MAAM,EAAE,CAAC,CAAA;IACvF,MAAM,CAAC,KAAK,C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AY,CAAC,MAAM,CAAC,CAAC,IAAI,CAAC,CACpF,CAAA;IACH,CAAC,CAAC,CAAA;AACJ,CAAC,CAAC,CAAA;AAEF,mGAAmG;AACnG,SAAS,iBAAiB,CACxB,QAA6B,EAC7B,UAAkB;IAElB,IAAI,QAAQ,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,KAAK,CAAA;IACvC,OAAO,EAAE,IAAI,EAAE,GAAG,UAAU,KAAK,QAAQ,CAAC,GAAG,CAAC,CAAC,EAAE,IAAI,EAAE,EAAE,EAAE,CAAC,IAAI,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,GAAG,EAAE,CAAA;AACnF,CAAC;AAED,eAAe,EAAE,gBAAgB,EAAE,aAAa,EAAE,OAAO,EAAE,OAAO,EAAE,CAAA"}
package/dist/schema.d.ts CHANGED
@@ -1,9 +1,9 @@
1
1
  /**
2
- * The schema of the options of the plugin, as validators of `@wtf/release-system/validator`: each a
2
+ * The schema of the options of the plugin, as validators of `@wtf/release/validator`: each a
3
3
  * Standard Schema, and a Standard JSON Schema of the JSON Schema of what it checks.
4
4
  *
5
5
  * - {@link mavenSchema}: the options the plugin is given, of the root of the config, `trains`,
6
- * `ecosystems`, `train` and `system`, and of its entry, as it checks them;
6
+ * `ecosystems` and `train`, and of its entry, as it checks them;
7
7
  * - {@link mavenOptionsSchema}: the options of its entry, `include`, `exclude`, `repository`,
8
8
  * `lookup`, `lookupAuth`, `command` and `args`, its own;
9
9
  * - {@link configSchema}: this package's part of a whole config of semantic-release, each entry of
@@ -22,11 +22,11 @@
22
22
  * @packageDocumentation
23
23
  * @module @wtf/semantic-release-maven/schema
24
24
  */
25
- import { type JsonSchema, type Validator } from '@wtf/release-system/validator';
25
+ import { type JsonSchema, type Validator } from '@wtf/release/validator';
26
26
  import { type RootOptions } from '@wtf/release-trains/schema';
27
27
  import type { MavenPluginOptions } from './index.ts';
28
28
  /** The options of an entry of the plugin, its own: every one of the options but those of the root. */
29
- export type MavenOptions = Omit<MavenPluginOptions, 'train' | 'trains' | 'ecosystems' | 'system'>;
29
+ export type MavenOptions = Omit<MavenPluginOptions, 'train' | 'trains' | 'ecosystems'>;
30
30
  /** The validator of the options of an entry of the plugin, its own. */
31
31
  export declare const mavenOptionsSchema: Validator<MavenOptions>;
32
32
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../src/schema.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,OAAO,EAGL,KAAK,UAAU,EAIf,KAAK,SAAS,EACf,MAAM,+BAA+B,CAAA;AAEtC,OAAO,EAAqB,KAAK,WAAW,EAAE,MAAM,4BAA4B,CAAA;AAEhF,OAAO,KAAK,EAAc,kBAAkB,EAAE,MAAM,YAAY,CAAA;AAEhE,sGAAsG;AACtG,MAAM,MAAM,YAAY,GAAG,IAAI,CAAC,kBAAkB,EAAE,OAAO,GAAG,QAAQ,GAAG,YAAY,GAAG,QAAQ,CAAC,CAAA;AAiBjG,uEAAuE;AACvE,eAAO,MAAM,kBAAkB,EAAE,SAAS,CAAC,YAAY,CAQrD,CAAA;AAEF;;;GAGG;AACH,eAAO,MAAM,WAAW,EAAE,SAAS,CAAC,WAAW,GAAG,YAAY,CAG7D,CAAA;AAED,wGAAwG;AACxG,eAAO,MAAM,YAAY,EAAE,SAAS,CAAC,MAAM,CAG1C,CAAA;AAED,2FAA2F;AAC3F,eAAO,MAAM,UAAU,EAAE,UAOxB,CAAA"}
1
+ {"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../src/schema.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,OAAO,EAGL,KAAK,UAAU,EAGf,KAAK,SAAS,EACf,MAAM,wBAAwB,CAAA;AAE/B,OAAO,EAAqB,KAAK,WAAW,EAAE,MAAM,4BAA4B,CAAA;AAGhF,OAAO,KAAK,EAAc,kBAAkB,EAAE,MAAM,YAAY,CAAA;AAEhE,sGAAsG;AACtG,MAAM,MAAM,YAAY,GAAG,IAAI,CAAC,kBAAkB,EAAE,OAAO,GAAG,QAAQ,GAAG,YAAY,CAAC,CAAA;AAiBtF,uEAAuE;AACvE,eAAO,MAAM,kBAAkB,EAAE,SAAS,CAAC,YAAY,CAQrD,CAAA;AAEF;;;GAGG;AACH,eAAO,MAAM,WAAW,EAAE,SAAS,CAAC,WAAW,GAAG,YAAY,CAG7D,CAAA;AAED,wGAAwG;AACxG,eAAO,MAAM,YAAY,EAAE,SAAS,CAAC,MAAM,CAG1C,CAAA;AAED,2FAA2F;AAC3F,eAAO,MAAM,UAAU,EAAE,UAOxB,CAAA"}
package/dist/schema.js CHANGED
@@ -1,9 +1,9 @@
1
1
  /**
2
- * The schema of the options of the plugin, as validators of `@wtf/release-system/validator`: each a
2
+ * The schema of the options of the plugin, as validators of `@wtf/release/validator`: each a
3
3
  * Standard Schema, and a Standard JSON Schema of the JSON Schema of what it checks.
4
4
  *
5
5
  * - {@link mavenSchema}: the options the plugin is given, of the root of the config, `trains`,
6
- * `ecosystems`, `train` and `system`, and of its entry, as it checks them;
6
+ * `ecosystems` and `train`, and of its entry, as it checks them;
7
7
  * - {@link mavenOptionsSchema}: the options of its entry, `include`, `exclude`, `repository`,
8
8
  * `lookup`, `lookupAuth`, `command` and `args`, its own;
9
9
  * - {@link configSchema}: this package's part of a whole config of semantic-release, each entry of
@@ -22,8 +22,9 @@
22
22
  * @packageDocumentation
23
23
  * @module @wtf/semantic-release-maven/schema
24
24
  */
25
- import { allOf, arrayOf, objectOf, pluginEntriesOf, stringOf } from '@wtf/release-system/validator';
25
+ import { allOf, arrayOf, objectOf, stringOf } from '@wtf/release/validator';
26
26
  import { rootOptionsSchema } from '@wtf/release-trains/schema';
27
+ import { pluginEntriesOf } from '@wtf/semantic-release/schema';
27
28
  /** A text of at least one character. */
28
29
  const text = stringOf({ minLength: 1 });
29
30
  /** The validator of `repository`: an `id` and a `url`, both required. */
@@ -1 +1 @@
1
- {"version":3,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
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wtf/semantic-release-maven",
3
- "version": "1.0.0",
3
+ "version": "2.0.0",
4
4
  "description": "The plugin of semantic-release that deploys the Maven modules of a train, by @wtf/release-maven: the version of the release written into the poms of the train's modules in prepare, and the last release of each other train into its modules and the dependencies on them, and each module the repository lacks deployed by mvn, in the order of their dependencies, in publish, the ones it has skipped, so a release that stopped part way is finished by running it again; and the schema of its options and of its part of a config (./schema, schema.json).",
5
5
  "keywords": [
6
6
  "java",
@@ -52,9 +52,11 @@
52
52
  },
53
53
  "dependencies": {
54
54
  "@standard-schema/spec": "^1.1.0",
55
- "@wtf/release-maven": "1.0.0",
56
- "@wtf/release-system": "^1.0.1",
57
- "@wtf/release-trains": "^7.1.0"
55
+ "@wtf/platform": "^1.0.0",
56
+ "@wtf/release": "^1.0.0",
57
+ "@wtf/release-maven": "^2.0.0",
58
+ "@wtf/release-trains": "^9.0.0",
59
+ "@wtf/semantic-release": "^1.0.0"
58
60
  },
59
61
  "devDependencies": {
60
62
  "@types/node": "^24.10.0",