repairCachedPackages abstract method

Future<Iterable<RepairResult>> repairCachedPackages(
  1. SystemCache cache, {
  2. bool packageFilter(
    1. String name,
    2. Version version
    )?,
})

Reinstalls all packages that have been previously installed into the system cache by this source.

If packageFilter is provided, only packages for which the filter returns true will be repaired. The filter receives the package name and version.

Returns a list of results indicating for each if that package was successfully repaired.

Implementation

Future<Iterable<RepairResult>> repairCachedPackages(
  SystemCache cache, {
  bool Function(String name, Version version)? packageFilter,
});