diff options
author | Lars Wirzenius <liw@liw.fi> | 2021-04-10 09:02:27 +0300 |
---|---|---|
committer | Lars Wirzenius <liw@liw.fi> | 2021-04-10 10:29:27 +0300 |
commit | e13ef6a773755e8eed4d0fb1e55f3bd80a6c5cfd (patch) | |
tree | 0ef79cad97789850efc5fcfe8073dd120b8473d7 /src/cmd | |
parent | f3ed6ba027dbb410161970c4a706192885d92a3d (diff) | |
download | obnam2-e13ef6a773755e8eed4d0fb1e55f3bd80a6c5cfd.tar.gz |
refactor: move ClientConfig into its own module
Diffstat (limited to 'src/cmd')
-rw-r--r-- | src/cmd/backup.rs | 3 | ||||
-rw-r--r-- | src/cmd/get_chunk.rs | 2 | ||||
-rw-r--r-- | src/cmd/init.rs | 2 | ||||
-rw-r--r-- | src/cmd/list.rs | 3 | ||||
-rw-r--r-- | src/cmd/list_files.rs | 2 | ||||
-rw-r--r-- | src/cmd/restore.rs | 2 | ||||
-rw-r--r-- | src/cmd/show_config.rs | 2 | ||||
-rw-r--r-- | src/cmd/show_gen.rs | 2 |
8 files changed, 10 insertions, 8 deletions
diff --git a/src/cmd/backup.rs b/src/cmd/backup.rs index bd36a3a..1091241 100644 --- a/src/cmd/backup.rs +++ b/src/cmd/backup.rs @@ -1,7 +1,8 @@ use crate::backup_progress::BackupProgress; use crate::backup_run::{BackupError, IncrementalBackup, InitialBackup}; use crate::chunkid::ChunkId; -use crate::client::{BackupClient, ClientConfig}; +use crate::client::BackupClient; +use crate::config::ClientConfig; use crate::error::ObnamError; use crate::fsiter::FsIterator; use crate::generation::NascentGeneration; diff --git a/src/cmd/get_chunk.rs b/src/cmd/get_chunk.rs index 385c4d5..c9d640e 100644 --- a/src/cmd/get_chunk.rs +++ b/src/cmd/get_chunk.rs @@ -1,6 +1,6 @@ use crate::chunkid::ChunkId; use crate::client::BackupClient; -use crate::client::ClientConfig; +use crate::config::ClientConfig; use crate::error::ObnamError; use std::io::{stdout, Write}; diff --git a/src/cmd/init.rs b/src/cmd/init.rs index f0ddb69..fb8a6af 100644 --- a/src/cmd/init.rs +++ b/src/cmd/init.rs @@ -1,4 +1,4 @@ -use crate::client::ClientConfigWithoutPasswords; +use crate::config::ClientConfigWithoutPasswords; use crate::error::ObnamError; use crate::passwords::{passwords_filename, Passwords}; use std::path::Path; diff --git a/src/cmd/list.rs b/src/cmd/list.rs index a3f059b..f48512b 100644 --- a/src/cmd/list.rs +++ b/src/cmd/list.rs @@ -1,4 +1,5 @@ -use crate::client::{BackupClient, ClientConfig}; +use crate::client::BackupClient; +use crate::config::ClientConfig; use crate::error::ObnamError; pub fn list(config: &ClientConfig) -> Result<(), ObnamError> { diff --git a/src/cmd/list_files.rs b/src/cmd/list_files.rs index 71b0d68..d490e85 100644 --- a/src/cmd/list_files.rs +++ b/src/cmd/list_files.rs @@ -1,6 +1,6 @@ use crate::backup_reason::Reason; use crate::client::BackupClient; -use crate::client::ClientConfig; +use crate::config::ClientConfig; use crate::error::ObnamError; use crate::fsentry::{FilesystemEntry, FilesystemKind}; use tempfile::NamedTempFile; diff --git a/src/cmd/restore.rs b/src/cmd/restore.rs index 183f207..c2cbb7f 100644 --- a/src/cmd/restore.rs +++ b/src/cmd/restore.rs @@ -1,6 +1,6 @@ use crate::backup_reason::Reason; -use crate::client::ClientConfig; use crate::client::{BackupClient, ClientError}; +use crate::config::ClientConfig; use crate::error::ObnamError; use crate::fsentry::{FilesystemEntry, FilesystemKind}; use crate::generation::{LocalGeneration, LocalGenerationError}; diff --git a/src/cmd/show_config.rs b/src/cmd/show_config.rs index 8acd1c8..88ee9ec 100644 --- a/src/cmd/show_config.rs +++ b/src/cmd/show_config.rs @@ -1,4 +1,4 @@ -use crate::client::ClientConfig; +use crate::config::ClientConfig; use crate::error::ObnamError; pub fn show_config(config: &ClientConfig) -> Result<(), ObnamError> { diff --git a/src/cmd/show_gen.rs b/src/cmd/show_gen.rs index 143aed6..5b786cf 100644 --- a/src/cmd/show_gen.rs +++ b/src/cmd/show_gen.rs @@ -1,5 +1,5 @@ use crate::client::BackupClient; -use crate::client::ClientConfig; +use crate::config::ClientConfig; use crate::error::ObnamError; use crate::fsentry::FilesystemKind; use indicatif::HumanBytes; |