forked from AssemblyScript/assemblyscript
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathclean.js
More file actions
16 lines (15 loc) · 478 Bytes
/
clean.js
File metadata and controls
16 lines (15 loc) · 478 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
var fs = require("fs");
var glob = require("glob");
glob("*", { cwd: __dirname + "/../dist" }, (err, matches) => {
if (err)
console.log("Failed to list files in 'dist/': " + err.message);
else
matches.forEach(match => {
fs.unlink(__dirname + "/../dist/" + match, err => {
if (err)
console.log("Failed to delete 'dist/" + match + "': " + err.message);
else
console.log("Deleted 'dist/" + match + "'");
});
});
});