Skip to content

Commit 593a4e7

Browse files
committed
Properly resolve the codemod
1 parent 1b9d988 commit 593a4e7

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

codemod.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,11 @@ program
2828
)
2929
.action(async (src, _, cmd) => {
3030
const options = cmd.optsWithGlobals();
31-
const replaceBarrelImports = path.resolve('src/replace-barrel-imports.js');
31+
const replaceBarrelImports = path.resolve(
32+
__dirname,
33+
`./src/${cmd.name()}.js`,
34+
);
35+
3236
await jscodeshift(replaceBarrelImports, [src], options);
3337
});
3438

0 commit comments

Comments
 (0)