Skip to content

Commit

Permalink
add install to prebuild and do better cleanup on scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
stephenegriffin committed Apr 22, 2021
1 parent 404e5ab commit da413f5
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 8 deletions.
2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,9 @@
},
"main": "Pages/mha.html",
"scripts": {
"prebuild": "npm install",
"build": "node tasks/build.js",
"prebuild-debug": "node tasks/build.js debug",
"build-debug": "node tasks/build.js debug",
"clean": "node tasks/clean.js",
"test": "echo \"Error: no test specified\" && exit 1"
Expand Down
9 changes: 1 addition & 8 deletions tasks/clean.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,4 @@ const rmdir = function (filepath) {

rmdir(path.join(__dirname, "..", "Pages"));
rmdir(path.join(__dirname, "..", "Content"));

const scriptsFolder = path.join(__dirname, "..", "Scripts");
fs.readdirSync(scriptsFolder).forEach((file, index) => {
const subpath = path.join(scriptsFolder, file);
if (fs.lstatSync(subpath).isDirectory()) {
rmdir(subpath);
}
});
rmdir(path.join(__dirname, "..", "Scripts"));

0 comments on commit da413f5

Please sign in to comment.