From 8d11eb64efa67f1d7a6902300fdffd2c7c08df6c Mon Sep 17 00:00:00 2001 From: Ruben Beltran del Rio Date: Fri, 18 Jul 2025 13:22:04 +0200 Subject: Apply clippy and formatting --- src/command/publish_archive.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/command/publish_archive.rs') diff --git a/src/command/publish_archive.rs b/src/command/publish_archive.rs index 96dda86..289b0c8 100644 --- a/src/command/publish_archive.rs +++ b/src/command/publish_archive.rs @@ -1,5 +1,5 @@ use crate::configuration::Configuration; -use std::io::{Error, ErrorKind::Other, Result}; +use std::io::{Error, Result}; use std::process::{Command, Stdio}; const COMMAND: &str = "rsync"; @@ -24,7 +24,7 @@ impl super::Command for PublishArchive { _: &str, ) -> Result<()> { let input = input.ok_or_else(|| { - Error::new(Other, "You must provide a location to publish the archive") + Error::other("You must provide a location to publish the archive") })?; Command::new(COMMAND) @@ -32,7 +32,7 @@ impl super::Command for PublishArchive { .stdout(Stdio::null()) .stderr(Stdio::null()) .status() - .map_err(|_| Error::new(Other, "Publishing requires rsync"))?; + .map_err(|_| Error::other("Publishing requires rsync"))?; Command::new(COMMAND) .arg("-r") @@ -44,7 +44,7 @@ impl super::Command for PublishArchive { .stdout(Stdio::null()) .stderr(Stdio::null()) .status() - .map_err(|_| Error::new(Other, "Rsync failed to publish."))?; + .map_err(|_| Error::other("Rsync failed to publish."))?; Ok(()) } -- cgit