Skip to content

Instantly share code, notes, and snippets.

@hackjutsu
Created January 8, 2017 16:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save hackjutsu/bc6e9a1345ac050490929c6530978829 to your computer and use it in GitHub Desktop.
Save hackjutsu/bc6e9a1345ac050490929c6530978829 to your computer and use it in GitHub Desktop.
Create a directory if not exist
var fs = require('fs');
var dir = './tmp';
if (!fs.existsSync(dir)){
fs.mkdirSync(dir);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment