cirectory cleanup

This commit is contained in:
Seth Trowbridge 2023-11-06 17:05:40 -05:00
parent 8d89cebe12
commit 9fbd811101
3 changed files with 13 additions and 4 deletions

View File

@ -129,7 +129,7 @@ if(arg._.length)
}
case "baker" :
{
const args = ["run", `-A`, `--no-lock`, `--config=${config.path}`, RootHost+"run.tsx", ...Deno.args];
const args = ["run", `-A`, `--no-lock`, `--config=${config.path}`, RootHost+"run-baker.tsx", ...Deno.args];
await SubProcess(args);
break;
}

View File

@ -15,6 +15,7 @@
"debug": "deno run -A --no-lock http://localhost:4507/cli.tsx debug",
"serve": "deno run -A --no-lock http://localhost:4507/cli.tsx serve",
"cloud": "deno run -A --no-lock http://localhost:4507/cli.tsx cloud",
"baker": "deno run -A --no-lock http://localhost:4507/cli.tsx baker",
"install": "deno install -A -r -f -n able http://localhost:4507/cli.tsx"
},
"compilerOptions": {

View File

@ -46,10 +46,18 @@ const options:SWCW.Options = {
const dir = Deno.cwd();
const folder = dir.substring(dir.lastIndexOf("\\")+1);
console.log("searching", dir);
const extensions = ["tsx", "ts", "jsx", "js"]
for await(const file of walk(dir, {includeDirs:false}))
const extensions = ["tsx", "ts", "jsx", "js"];
try
{
await Deno.remove(".bake", { recursive: true });
console.log("rebuilding baked files");
}
catch(e)
{
console.log("fresh bake");
}
for await(const file of walk(dir, {includeDirs:false}))
{
const pathClean = file.path.replaceAll("\\", "/");
const pathRel = pathClean.substring(dir.length);