use std::path::Path; use cargo::{ core::Workspace, ops::{clean, CleanOptions}, util::{context::GlobalContext, interning::InternedString}, CargoResult, }; use crate::cli::Args; pub fn clean_int(path: &Path, cli: &Args) -> CargoResult<()> { let gctx = GlobalContext::default()?; let workspace = Workspace::new(path, &gctx)?; let opts = CleanOptions { gctx: &gctx, spec: vec![], targets: vec![], profile_specified: false, requested_profile: InternedString::new("dev"), doc: cli.doc, dry_run: cli.dry_run, }; clean(&workspace, &opts) }