Skip to content

Commit

Permalink
Symlink creation fails on windows
Browse files Browse the repository at this point in the history
Switching to type=junction seems to fix the issue. Here is a related ticket on node: nodejs/node#18518
  • Loading branch information
dubzzz committed Apr 21, 2020
1 parent 3681cca commit c6e50f8
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion e2e/Utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ export const linkJestPackage = (packageName: string, cwd: Config.Path) => {
const destination = path.resolve(cwd, 'node_modules/', packageName);
makeDir.sync(destination);
rimraf.sync(destination);
fs.symlinkSync(packagePath, destination, 'dir');
fs.symlinkSync(packagePath, destination, 'junction');
};

export const makeTemplate = (
Expand Down Expand Up @@ -105,6 +105,7 @@ export const writeSymlinks = (
fs.symlinkSync(
path.resolve(directory, ...fileOrPath.split('/')),
path.resolve(directory, ...symLinkPath.split('/')),
'junction',
);
});
};
Expand Down

0 comments on commit c6e50f8

Please sign in to comment.