From 92b05a877eb772985d2f4fc9cd198ca642b69b6a Mon Sep 17 00:00:00 2001 From: diogo464 Date: Tue, 8 Feb 2022 09:21:12 +0000 Subject: removed old code --- dotup_cli/src/commands/install.rs | 25 ------------------------- 1 file changed, 25 deletions(-) delete mode 100644 dotup_cli/src/commands/install.rs (limited to 'dotup_cli/src/commands/install.rs') diff --git a/dotup_cli/src/commands/install.rs b/dotup_cli/src/commands/install.rs deleted file mode 100644 index 6d9fbf7..0000000 --- a/dotup_cli/src/commands/install.rs +++ /dev/null @@ -1,25 +0,0 @@ -use std::path::PathBuf; - -use super::prelude::*; - -/// Install links. (Creates symlinks). -/// -/// Installing a link will create the necessary directories. -/// If a file or directory already exists at the location a link would be installed this command will fail. -#[derive(Parser)] -pub struct Opts { - /// The files/directories to install. - #[clap(min_values = 1, default_value = ".")] - paths: Vec, -} - -pub fn main(config: Config, opts: Opts) -> anyhow::Result<()> { - let depot = utils::read_depot(&config.archive_path)?; - - for link in utils::collect_links_by_base_paths(&depot, &opts.paths) { - log::info!("Installing link {}", link); - depot.install_link(link, &config.install_path)?; - } - - Ok(()) -} -- cgit