String directory({String? fromDirectory}) { final dir = path.dirname(pubspecYaml); if (fromDirectory == null) { return dir; } return path.relative(dir, from: fromDirectory); }