fix(misc): calculate cwd relative path correctly for generators and executors (#18933)

This commit is contained in:
Leosvel Pérez Espinosa 2023-09-06 19:17:35 +01:00 committed by GitHub
parent 0fa0c4ba35
commit ace8f8cf97
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 3 additions and 3 deletions

View File

@ -57,6 +57,6 @@ export function readTargetOptions<T = any>(
targetConfiguration,
schema,
defaultProject,
relative(context.cwd, context.root)
relative(context.root, context.cwd)
) as T;
}

View File

@ -364,7 +364,7 @@ export async function generate(cwd: string, args: { [k: string]: any }) {
projectsConfigurations,
nxJsonConfiguration
),
relative(cwd, workspaceRoot),
relative(workspaceRoot, cwd),
verbose
);

View File

@ -150,7 +150,7 @@ async function runExecutorInternal<T extends { success: boolean }>(
targetConfig,
schema,
project,
relative(cwd, root),
relative(root, cwd),
isVerbose
);