diff --git a/buildWeb.js b/buildWeb.js index 522055a..e7efe29 100644 --- a/buildWeb.js +++ b/buildWeb.js @@ -10,7 +10,7 @@ fs.existsSync(buildDir) && fs.rmSync(buildDir, { recursive: true }); fs.mkdirSync(buildDir) fs.mkdirSync(`${buildDir}/modules`); -fs.copyFileSync('./_headers', `${buildDir}/_headers`); +fs.copyFileSync('./src-web/_headers', `${buildDir}/_headers`); const ids = [] @@ -26,7 +26,7 @@ fs.readdirSync(sourceDir).forEach((file) => { console.log("Files built: " + ids.join(', ')) console.log("Generating index.html...") -const template = fs.readFileSync('./template-index.html').toString() +const template = fs.readFileSync('./src-web/template-index.html').toString() const indexHtml = template.replace( '%DYNAMIC_SCHEMA_LIST%', ids.map( diff --git a/package.json b/package.json index 1a0dad1..5b54a0b 100644 --- a/package.json +++ b/package.json @@ -8,7 +8,7 @@ }, "private": true, "scripts": { - "build": "rm -rf ./tsp-output && npx tsp compile .", + "build": "rm -rf ./tsp-output && npx tsp compile ./src-tsp", "build-web": "npm run build && node ./buildWeb.js" } } diff --git a/main.tsp b/src-tsp/main.tsp similarity index 100% rename from main.tsp rename to src-tsp/main.tsp diff --git a/modules.tsp b/src-tsp/modules.tsp similarity index 100% rename from modules.tsp rename to src-tsp/modules.tsp diff --git a/_headers b/src-web/_headers similarity index 100% rename from _headers rename to src-web/_headers diff --git a/template-index.html b/src-web/template-index.html similarity index 100% rename from template-index.html rename to src-web/template-index.html