fix(release): ensure generatorOptions and rootVersionActionsOptions are passed to updateLockfile function (#30796)

This commit is contained in:
Thomas Dekiere 2025-04-25 14:41:03 +02:00 committed by GitHub
parent cd55dfcb3e
commit 69ea6327d3
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 7 additions and 2 deletions

View File

@ -1000,7 +1000,7 @@ To fix this you will either need to add a package.json file at that location, or
// Return the version data so that it can be leveraged by the overall version command
return {
data: versionData,
callback: async (tree, opts) => {
callback: async (tree, { generatorOptions, ...opts }) => {
const changedFiles: string[] = [];
const deletedFiles: string[] = [];
@ -1013,6 +1013,7 @@ To fix this you will either need to add a package.json file at that location, or
...(await updateLockFile(cwd, {
...opts,
useLegacyVersioning: true,
options: generatorOptions,
}))
);
return { changedFiles, deletedFiles };

View File

@ -17,7 +17,10 @@ import chalk = require('chalk');
export const afterAllProjectsVersioned: AfterAllProjectsVersioned = async (
cwd: string,
opts: {
{
rootVersionActionsOptions,
...opts
}: {
dryRun?: boolean;
verbose?: boolean;
rootVersionActionsOptions?: Record<string, unknown>;
@ -27,6 +30,7 @@ export const afterAllProjectsVersioned: AfterAllProjectsVersioned = async (
changedFiles: await updateLockFile(cwd, {
...opts,
useLegacyVersioning: false,
options: rootVersionActionsOptions,
}),
deletedFiles: [],
};