diff --git a/coffee_core/src/coffee.rs b/coffee_core/src/coffee.rs index 1bf247e..f3e1d7e 100644 --- a/coffee_core/src/coffee.rs +++ b/coffee_core/src/coffee.rs @@ -270,7 +270,7 @@ impl PluginManager for CoffeeManager { old_root_path, new_root_path ); - let script = format!("cp -r -T {old_root_path} {new_root_path}"); + let script = format!("mkdir -p {new_root_path} || echo '{new_root_path} already exist' && cp -r {old_root_path}/ {new_root_path}"); sh!(self.config.root_path.clone(), script, verbose); log::debug!( "Done! copying directory from {} inside the new one {}",