docs: function stat(dir, callback) {
      return new Promise(resolve => {
          fs.lstat(dir, (err, stats = null) => {
              let result = callback && callback(err, stats);
  
              // 处理异步
              if (result && result instanceof Promise) {
                  result.then(() => resolve(stats));
              } else {
                  resolve(stats);
              }
          });
      });
  }