docs: function getDirectories (basePath, includeFiles, userSuppliedFilterFn) {
  
    var items;
    try {
      items = fs.readdirSync(basePath);
    }
    catch (err) {
  
      // probably a file not a dir, but let's check error message to be sure
      if (includeFiles && String(err.stack).match(/ENOTDIR/)) {
        return [ basePath ];
      }
  
      // something is wrong, perhaps directory read permissions problem
      // maybe throw err instead
      console.error(err.stack);
      return [];
    }
  
    return items.filter(function (file) {
  
      var absPath = path.join(basePath, file);
  
      var stats = fs.lstatSync(absPath);
      if (stats.isSymbolicLink()) {
        return false;
      }
  
      var isDir = includeFiles ? true : stats.isDirectory();
      var isNotDotFile = path.basename(file).indexOf('.') !== 0;
      return isDir && isNotDotFile && (userSuppliedFilterFn || allOK)(absPath);
  
    })
    .map(function (item) {
      // return path.join(basePath, item);
      return item;
    })
    .sort();
  }