mirror of
https://github.com/Pomax/BezierInfo-2.git
synced 2025-08-12 03:34:12 +02:00
safety
This commit is contained in:
11
tools/buildmark.js
Normal file
11
tools/buildmark.js
Normal file
@@ -0,0 +1,11 @@
|
||||
var fs = require('fs');
|
||||
var markfile = '.buildmark';
|
||||
var resolve = process.argv.indexOf('resolve') > -1;
|
||||
|
||||
if (!resolve) {
|
||||
fs.writeFileSync(markfile, Date.now());
|
||||
} else {
|
||||
let mark = parseInt(fs.readFileSync(markfile).toString());
|
||||
console.log(`Build ran in ${(Date.now() - mark)/1000} seconds.`);
|
||||
fs.unlinkSync(markfile);
|
||||
}
|
Reference in New Issue
Block a user