Skip to content

Commit

Permalink
Build ensure dist/ folder exists
Browse files Browse the repository at this point in the history
before writing built files into it.
  • Loading branch information
ghybs committed Sep 22, 2016
1 parent 05c75ff commit af07888
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions build/build.js
Expand Up @@ -88,6 +88,13 @@ exports.build = function (callback, metaData, compsBase32, buildName) {
oldSrc = loadSilently(srcPath),
srcDelta = getSizeDelta(newSrc, oldSrc, true);

// Make sure the dist/ folder exists.
try {
fs.accessSync(pathPart, fs.F_OK);
} catch (err) {
fs.mkdirSync(pathPart);
}

pathPart += filenamePart;

console.log("\tNon-minified: " + bytesToKB(newSrc.length) + srcDelta);
Expand Down

0 comments on commit af07888

Please sign in to comment.