Merge pull request #97 from the-sun-will-rise-tomorrow/mkdir-path

src/generate.ts: Create the nixExprPath directory if it doesn't exist
This commit is contained in:
Stéphan Kochen
2024-12-11 08:44:56 +01:00
committed by GitHub
+1
View File
@@ -395,6 +395,7 @@ export default async (
USES_PNP_LINKER: configuration.get("nodeLinker") === "pnp",
USES_NM_LINKER: configuration.get("nodeLinker") === "node-modules",
}).replace(/\n\n\n+/g, "\n\n");
await xfs.mkdirpPromise(ppath.dirname(nixExprPath));
await xfs.writeFilePromise(nixExprPath, projectExpr);
// Create a wrapper if it does not exist yet.