Whether a package with name has already been added.
name
bool hasPackage(String name) => _packages.any((e) => e.name == name);