pub mod run;
use std::path::PathBuf;
#[derive(Debug, Clone, PartialEq, Eq)]
pub enum SyncOperand {
Local(PathBuf),
Remote(RemoteEndpoint),
}
#[derive(Debug, Clone, PartialEq, Eq)]
pub enum RemoteEndpoint {
Tcp { addr: String, path: Option<String> },
Ssh { host: String, path: String },
}
#[derive(Debug)]
pub enum Action {
Sync {
src: SyncOperand,
dst: SyncOperand,
threshold: f32,
checksum: bool,
dry_run: bool,
delete: bool,
fsync: bool,
large_file_parallel_threshold: u64,
large_file_parallel_workers: usize,
network_file_concurrency: usize,
ignores: Vec<String>,
quiet: bool,
},
Listen {
addr: String,
dst: PathBuf,
fsync: bool,
quiet: bool,
},
Serve {
addr: String,
src: PathBuf,
threshold: f32,
checksum: bool,
ignores: Vec<String>,
quiet: bool,
},
InternalStdioReceive {
dst: PathBuf,
fsync: bool,
ignores: Vec<String>,
quiet: bool,
},
InternalStdioSend {
src: PathBuf,
threshold: f32,
checksum: bool,
delete: bool,
ignores: Vec<String>,
quiet: bool,
},
InternalChunkWrite {
dst: PathBuf,
transfer_id: String,
quiet: bool,
},
}