Skip to content

Commit

Permalink
fix: use cp instead of rename to copy dir
Browse files Browse the repository at this point in the history
  • Loading branch information
observerw committed Jun 24, 2024
1 parent bb08ede commit ceb70dc
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/lang/loader.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,9 @@ abstract class Loader<T> {
file: `${tmpPath}/${pkg}.tgz`,
cwd: tmpPath,
});
await fs.rename(`${tmpPath}/package`, `${this._basePath}/${pkg}`);
await fs.cp(`${tmpPath}/package`, `${this._basePath}/${pkg}`, {
recursive: true,
});
await fs.rmdir(tmpPath, { recursive: true });
}

Expand Down

0 comments on commit ceb70dc

Please sign in to comment.