Skip to content

Commit

Permalink
fix(core): local plugins should work on windows (#13801)
Browse files Browse the repository at this point in the history
(cherry picked from commit 75c34c3)
  • Loading branch information
AgentEnder authored and FrozenPandaz committed Dec 19, 2022
1 parent 1a712d7 commit 809df6a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/nx/src/utils/nx-plugin.ts
Expand Up @@ -21,6 +21,7 @@ import {
createProjectRootMappingsFromProjectConfigurations,
findProjectForPath,
} from '../project-graph/utils/find-project-for-path';
import { normalizePath } from './path';

export type ProjectTargetConfigurator = (
file: string
Expand Down Expand Up @@ -195,7 +196,7 @@ function findNxProjectForImportPath(
): string | null {
const tsConfigPaths: Record<string, string[]> = readTsConfigPaths(root);
const possiblePaths = tsConfigPaths[importPath]?.map((p) =>
path.relative(root, path.join(root, p))
normalizePath(path.relative(root, path.join(root, p)))
);
if (possiblePaths?.length) {
const projectRootMappings =
Expand Down

0 comments on commit 809df6a

Please sign in to comment.