diff options
author | Aaron O'Mullan <aaron.omullan@friendco.de> | 2014-03-31 18:28:51 -0700 |
---|---|---|
committer | Aaron O'Mullan <aaron.omullan@friendco.de> | 2014-03-31 18:28:51 -0700 |
commit | 84d703c6f5ffd8a3cfc652083ad17411f73b51ba (patch) | |
tree | e0da213ecd42b9409db15af28fba4879a2bf072e /lib | |
parent | 138dc1f2dea9d32241ee5e8f2c655613cdc168bb (diff) | |
download | gitbook-84d703c6f5ffd8a3cfc652083ad17411f73b51ba.zip gitbook-84d703c6f5ffd8a3cfc652083ad17411f73b51ba.tar.gz gitbook-84d703c6f5ffd8a3cfc652083ad17411f73b51ba.tar.bz2 |
Ensure destination dir exists before building
Diffstat (limited to 'lib')
-rw-r--r-- | lib/generate/index.js | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/generate/index.js b/lib/generate/index.js index 351cc82..a06aa8b 100644 --- a/lib/generate/index.js +++ b/lib/generate/index.js @@ -23,6 +23,10 @@ var generate = function(root, output, options) { // Clean output folder return fs.remove(output) + .then(function() { + return fs.mkdirp(output); + }) + // List all files in the repository .then(function() { return Q.nfcall(glob, "**/*", { |