Skip to main content

ripsync_core/
lib.rs

1//! ripsync core: pure sync logic — delta engine, checksums, parallel walk,
2//! plan/apply, metadata and symlink-containment safety.
3//!
4//! No terminal I/O lives here; the CLI crate owns presentation.
5// The whole crate is `forbid(unsafe_code)` — except in the isolated platform IO
6// modules: the Linux `io::uring` backend and the Windows `io::windows` backend,
7// which must call raw OS APIs. A crate-level `forbid` cannot be locally relaxed,
8// so on those configurations we drop to `deny`, which still rejects `unsafe`
9// everywhere that does not explicitly `allow` it. Every `unsafe` block in those
10// modules carries a `// SAFETY:` comment.
11#![cfg_attr(
12    not(any(
13        all(target_os = "linux", feature = "io-uring"),
14        windows,
15        target_os = "macos"
16    )),
17    forbid(unsafe_code)
18)]
19#![cfg_attr(
20    any(
21        all(target_os = "linux", feature = "io-uring"),
22        windows,
23        target_os = "macos"
24    ),
25    deny(unsafe_code)
26)]
27#![warn(clippy::pedantic)]
28#![allow(clippy::module_name_repetitions)]
29
30pub mod apply;
31pub mod checksum;
32pub mod control;
33pub mod copy;
34pub mod delta;
35pub mod error;
36pub mod filter;
37pub mod index;
38pub mod io;
39pub mod meta;
40pub mod net;
41pub mod plan;
42pub mod report;
43pub mod tune;
44pub mod util;
45pub mod verify;
46pub mod walk;
47
48pub use control::RunControl;
49pub use error::{Error, Result};
50pub use filter::Filter;
51pub use report::{Event, Reporter, RunPhase, RunStatus, Stats};