pub fn delete_dist(dir: PathBuf) -> Result<(), ExecutionError> {
    let target = dir.join("dist");
    if target.exists() {
        if let Err(err) = fs::remove_dir_all(&target) {
            return Err(ExecutionError::RemoveArtifactsFailed {
                target: target.to_str().map(|s| s.to_string()),
                source: err,
            });
        }
    }

    Ok(())
}
Deletes the entire `dist/` directory. Notably, this is where we keep
several Cargo artifacts, so this means the next build will be much
slower.
packages/perseus-cli/src/lib.rs