code: function mkdir (dir) {
  
      var currPath = dir;
      var toMakeUpPath = [];
  
      while (!fs.existsSync(currPath)) {
          toMakeUpPath.unshift(currPath);
          currPath = path.dirname(currPath);
      }
  
      toMakeUpPath.forEach(function (pathItem) {
          fs.mkdirSync(pathItem);
      });
  }
docs: 创建目录，包括子文件夹