code: async function scanDir (dir, ret_absolute)
  {
  return new Promise( async function(resolve, reject){
      // console.log(dir);
      fs.readdir(dir, function(err, files){
          let dir_arr = [];
          if( ! files ){
              return resolve(dir_arr);
          }
          files.forEach(function(elm){
              if( elm.indexOf('.') == -1 ){ // 没有点号 目录
                  // 返回全路径
                  if( ret_absolute ){
                      elm = path.join(dir, elm);
                  }
                  dir_arr.push(elm);
              }
          });
          resolve(dir_arr);
      });
  });
  }
docs: 扫描路径