-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCargo.toml
More file actions
158 lines (126 loc) · 5.01 KB
/
Cargo.toml
File metadata and controls
158 lines (126 loc) · 5.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
[package]
name = "rustdupe"
version = "0.3.0"
edition = "2021"
rust-version = "1.85"
description = "Smart duplicate file finder with interactive TUI"
authors = ["RustDupe Team"]
license = "MIT"
repository = "https://github.com/MasuRii/RustDupe"
keywords = ["duplicate", "files", "deduplication", "tui", "cli"]
categories = ["command-line-utilities", "filesystem"]
readme = "README.md"
[dependencies]
# CLI Argument Parsing - clap is the gold standard
# 13.7k GitHub stars, excellent docs, derive macros, shell completions
clap = { version = "4", features = ["derive", "env", "unicode"] }
# TUI Framework - Ratatui is the actively maintained successor to tui-rs
# Cross-platform via crossterm backend, 23k+ GitHub stars
# Pinned to 0.28.x for Rust 1.85 MSRV compatibility
ratatui = { version = "0.28", default-features = false, features = ["crossterm"] }
# Terminal Backend - MUST use crossterm for Windows support
# termion is Unix-only, termwiz is more complex
crossterm = "0.28"
# Hashing - BLAKE3 is optimal for file deduplication
# 2.8-10x faster than SHA-256, parallel processing, cryptographically secure
# Multi-threaded scaling: 8.4 GB/s single-thread -> 92 GB/s on 16 cores
blake3 = { version = "1", features = ["mmap", "rayon"] }
# Memory-mapped I/O - memmap2 for parallel hashing of large files
memmap2 = "0.9"
# Directory Walking - jwalk for parallel traversal (4x faster than walkdir)
# Provides sorted streaming results, rayon-powered parallelism
jwalk = "0.8"
# Keep walkdir as fallback for simpler single-threaded cases
walkdir = "2"
# Parallel Processing - Rayon is the de facto standard
# Work-stealing thread pool, near-linear scaling with cores
rayon = "1.10"
# Progress Bars - indicatif is mature and feature-rich
# 90M+ downloads, integrates with rayon, multi-bar support
indicatif = "0.17"
# Trash Support - Cross-platform recycle bin
# Windows: IFileOperation, macOS: NSFileManager, Linux: Freedesktop spec
# Note: Minor thread-safety caveat on Linux with mount operations
trash = "5"
# Human-Readable File Sizes - bytesize is lightweight and popular
# 3.3M downloads/month, supports SI (KB/MB) and IEC (KiB/MiB)
bytesize = "2"
# Ignore Patterns - gitignore-style pattern matching
# Same library used by ripgrep, handles .gitignore files natively
ignore = "0.4"
# Error Handling - anyhow for applications, thiserror for libraries
anyhow = "1"
thiserror = "1"
# Database - rusqlite for persistent hash caching
# Using bundled feature for self-contained cross-platform builds
rusqlite = { version = "0.31", features = ["bundled"] }
# Logging
log = "0.4"
env_logger = "0.11"
# Signal Handling - Graceful Ctrl+C shutdown
# Cross-platform, supports SIGTERM/SIGHUP with "termination" feature
ctrlc = { version = "3.4", features = ["termination"] }
# Config/Cache Directory Discovery - XDG on Linux, AppData on Windows
directories = "5"
# System Information - sysinfo for detecting system resources (memory, disk type)
# Enables adaptive buffer sizing and optimized resource allocation
sysinfo = "0.30"
# Configuration File Parsing - TOML is the Rust ecosystem standard
# Used with figment for layered config (defaults < file < env < CLI)
toml = "0.8"
toml_edit = "0.22"
# Layered Configuration - figment enables hierarchical config merging
# Supports: defaults < config file < environment variables < CLI flags
figment = { version = "0.10", features = ["toml", "env"] }
# Unicode Path Normalization - Critical for macOS NFD vs NFC issues
unicode-normalization = "0.1"
# Terminal coloring
yansi = "1.0"
# Fuzzy string matching for config suggestions
strsim = "0.11"
# Bloom filter for quick duplicate rejection
growable-bloom-filter = "2.0"
# Perceptual Image Similarity - FC-005
# Disable default image features and explicitly enable needed formats
# JPEG uses zune-jpeg which has broken ARM64 NEON code in Rust 1.85
# See: https://github.com/etemesi254/zune-image/issues/343
image = { version = "0.25", default-features = false, features = ["bmp", "gif", "png", "tiff", "webp", "rayon"] }
image_hasher = "2.0"
bk-tree = "0.5"
# Fuzzy Text Document Matching - FC-006
simhash = "0.2"
pdf-extract = "0.10"
docx-rs = "0.4"
# Serialization for JSON/CSV output
serde = { version = "1", features = ["derive"] }
serde_json = "1"
csv = "1"
chrono = { version = "0.4", features = ["serde"] }
regex = "1"
sha2 = "0.10"
# Templating for HTML reports
askama = "0.12"
base64 = "0.22.1"
[build-dependencies]
# Windows manifest embedding for long path support (>260 chars)
embed-resource = "2"
[dev-dependencies]
# Property-based testing
proptest = "1"
# Temp file/directory creation for tests
tempfile = "3"
# File modification time for tests
filetime = "0.2"
# Benchmarking
criterion = "0.5"
[[bench]]
name = "scan_benchmarks"
harness = false
[profile.release]
lto = "thin" # Link-time optimization (good balance)
codegen-units = 1 # Better optimization, slower compile
strip = true # Strip symbols for smaller binary
panic = "abort" # Smaller binary, faster execution
[profile.release-fast]
inherits = "release"
lto = "fat" # Maximum optimization