feat(cleaners): add main async runner

Adds a Runner able to work upon a set of cleaners that
work in parallel.
This commit is contained in:
Matteo Settenvini 2025-01-25 02:19:48 +01:00
parent cc1a66726e
commit 5507a1dd21
Signed by: matteo
GPG key ID: 1C1B12600D81DE05
8 changed files with 510 additions and 6 deletions

View file

@ -1,8 +1,23 @@
// SPDX-FileCopyrightText: Matteo Settenvini <matteo.settenvini@montecristosoftware.eu>
// SPDX-License-Identifier: EUPL-1.2
use std::path::PathBuf;
use clap::Parser;
/// A tool to clean up sysroots for Linux embedded devices to save storage space.
#[derive(Parser, Debug)]
#[command(version, about, long_about = None)]
pub struct Args {}
pub struct Args {
/// Simulate operations without carrying them out
#[arg(short = 'n', long, default_value_t = false)]
pub dry_run: bool,
/// Instead of simply removing files, move them to the
/// given location, preserving their relative folder structure
#[arg(long)]
pub split_to: Option<PathBuf>,
/// The location of the sysroot to clean up
pub sysroot_location: PathBuf,
}