Ensure the 'flattened' directory exists
commit3e424fc3b26337b4c9edaf2a8f0c58e0af1ab93b
authorHarry Garrood <harry@garrood.me>
dateWed 29 Jul 2015, 17:19 (11 years ago)
parent54831da
tests/support/setup.js+9
@@ -1,6 +1,15 @@
11var glob = require("glob");
22var fs = require("fs");
33
4+try {
5+ fs.mkdirSync("./flattened");
6+} catch(e) {
7+ // ignore the error if it already exists
8+ if (e.code !== "EEXIST") {
9+ throw(e);
10+ }
11+}
12+
413glob("bower_components/*/src/**/*.{js,purs}", function(err, files) {
514 if (err) throw err;
615 files.forEach(function(file) {