cleanUp method

Future cleanUp(
  1. PreparedPackageRef preparedPackageRef
)
inherited

If the prepared package contains anything that has to be cleaned up (like created temp directories) then cleanUp takes care of that

Implementation

Future cleanUp(PreparedPackageRef preparedPackageRef) {
  stdout.writeln('Cleaning up');
  if (preparedPackageRef.tempDirectory != null) {
    return Directory(preparedPackageRef.tempDirectory!)
        .delete(recursive: true);
  }
  return Future.value();
}