Syncly — File Synchronizer CLI
Cross-Device File Synchronization & Tracking Utility in Rust
Reliable and high-performance Rust command-line tool for bi-directional and recursive directory synchronization across devices, featuring change status tracking, dry-run previews, synchronization history logs, and configurable ignore patterns.
Technologies & Tools Employed
ENGINEERING STATUS: VERIFIED & SHIPPED
Syncly — Cross-Device File Synchronizer CLI
Syncly is a high-performance, memory-safe command-line tool written in Rust for bi-directional, recursive directory synchronization across devices. Engineered for speed and data integrity, it features granular change status tracking, dry-run preview simulation, synchronization history logs, and
.synclyignorepattern parsing.
1. Motivation & Problem Statement
Engineers working across multiple workstations, remote servers, and external drives frequently require fast, predictable directory synchronization without the bloat, slow runtime overhead, or unexpected file overwrites common in legacy utilities.
Syncly was architected in Rust to provide:
- Zero-Latency Traversal: Parallel asynchronous directory scanning capable of walking tens of thousands of nested files in milliseconds.
- Deterministic Change Tracking: Cryptographic hashing and file metadata comparisons to prevent silent overwrites or corruptions.
- Safety-First Previews: First-class dry-run execution providing colored terminal diffs before any destructive file operation occurs.
+-------------------------------------------------------------------------+
| Syncly CLI Pipeline |
| |
| [Source Directory] [Target Directory] |
| │ │ |
| ▼ ▼ |
| Parallel FS Walker (Tokio) Parallel FS Walker (Tokio) |
| │ │ |
| ▼ ▼ |
| .synclyignore Filter .synclyignore Filter |
| │ │ |
| └──────────────────────┬──────────────────────┘ |
| ▼ |
| Delta Engine & Hash Verification |
| (Size + Modification Time + SHA-256) |
| │ |
| ▼ |
| ┌──────────────────┴──────────────────┐ |
| ▼ ▼ |
| [Dry Run Preview] [Atomic Execution] |
| - Terminal Color Diffs - Temp-file writes |
| - Change Summary Matrix - Atomic OS renames |
| - Sync Audit Log |
+-------------------------------------------------------------------------+
2. Key Features
- Bi-Directional & Recursive Sync: Traverses deeply nested folder trees, resolving relative paths and symlinks according to configurable policies.
- Change Status Tracking: Categorizes every change into explicit states:
ADDED,MODIFIED,DELETED,UNCHANGED, orCONFLICT. - Atomic Operations: Uses temporary file writes followed by atomic OS-level renames (
fs::rename) so incomplete transfers or interrupted network paths never leave corrupted files on disk. - Dry-Run Mode (
--dry-run): Outputs a formatted change matrix with exact file paths, sizes, and actions before committing any disk mutations. - Configurable Ignore Rules: Evaluates
.synclyignorepatterns with standard globbing rules (supporting wildcards, directory exclusion, and comments). - Execution History: Maintains a lightweight SQLite or structured JSON log recording timestamps, sync durations, transfer bytes, and error traces.
3. Technology Stack & Implementation Details
- Language: Rust (2021 Edition)
- Concurrency & Async I/O: Tokio asynchronous runtime for non-blocking file system traversal
- CLI Parsing & Formatting:
clap(v4 with derive macros),coloredfor terminal formatting, andindicatiffor progress bars - File System Utilities:
walkdir,ignore(ripgrep gitignore engine),tempfile - Integrity Verification: Fast hashing via
blake3andsha2
4. Key Engineering Achievements
- Achieved sub-second scanning across 100,000+ files by utilizing parallel work-stealing directory threads.
- Prevented race conditions and data loss during concurrent transfers through transactional temp-to-final atomic swaps.
- Cross-platform binary compilation supporting macOS (ARM64/x86_64), Linux (glibc/musl), and Windows.
