packageDir method

String packageDir(
  1. String rootPath
)

Implementation

String packageDir(String rootPath) {
  final normalized = p.normalize(rootPath);
  final name = p.basename(normalized);
  final hash = normalized.hashCode.toRadixString(16);

  return p.join(
    _temp.asDirectory.path,
    "${name.isEmpty ? "root" : name}_$hash",
  );
}