1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2025-01-10 08:09:06 -05:00
denoland-deno/tests/specs/compile/code_cache/cleanup.ts
David Sherret 074444ab6c
fix(compile): be more deterministic when compiling the same code in different directories (#27395)
Additionaly, this no longer unnecessarily stores the source twice for
file specifiers and fixes some sourcemap issues.

Closes https://github.com/denoland/deno/issues/27284
2024-12-19 12:53:52 -05:00

11 lines
306 B
TypeScript

import { tmpdir } from "node:os";
// cleanup the code cache file from a previous run
try {
if (Deno.build.os === "windows") {
Deno.removeSync(tmpdir() + "\\deno-compile-using_code_cache.exe.cache");
} else {
Deno.removeSync(tmpdir() + "\\deno-compile-using_code_cache.cache");
}
} catch {
}