Implement silent background cleanup of notes that have been in trash for more than 30 days, fulfilling the promise already shown in the Trash view UI. Safety model (all 5 checks must pass per file): - _trashed: true in frontmatter - _trashed_at present and parseable as date - Date strictly >30 days ago - File exists on disk - File path inside vault root Uses trash::delete (OS trash) with fs::remove_file fallback. Triggers on app launch and window focus (max once/hour). Audit log at .laputa/purge.log. Dry-run mode for testing. Also fixes pre-commit hook to read CodeScene thresholds from .codescene-thresholds instead of hardcoded values, matching the ratchet mechanism documented in CLAUDE.md. ADR-0042 documents the safety model. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
45 lines
1.0 KiB
TOML
45 lines
1.0 KiB
TOML
[package]
|
|
name = "laputa"
|
|
version = "0.1.0"
|
|
description = "Personal knowledge and life management app"
|
|
authors = ["you"]
|
|
license = ""
|
|
repository = ""
|
|
edition = "2021"
|
|
rust-version = "1.77.2"
|
|
|
|
[lib]
|
|
name = "laputa_lib"
|
|
crate-type = ["staticlib", "cdylib", "rlib"]
|
|
|
|
[build-dependencies]
|
|
tauri-build = { version = "2.5.4", features = [] }
|
|
|
|
[dependencies]
|
|
serde_json = "1.0"
|
|
serde = { version = "1.0", features = ["derive"] }
|
|
serde_yaml = "0.9"
|
|
log = "0.4"
|
|
tauri = { version = "2.10.0", features = ["protocol-asset", "devtools"] }
|
|
tauri-plugin-log = "2"
|
|
gray_matter = "0.2"
|
|
walkdir = "2"
|
|
chrono = { version = "0.4", features = ["serde"] }
|
|
reqwest = { version = "0.12", features = ["json", "stream"] }
|
|
tokio = { version = "1", features = ["rt-multi-thread", "macros"] }
|
|
futures-util = "0.3"
|
|
base64 = "0.22"
|
|
regex = "1"
|
|
dirs = "5"
|
|
tauri-plugin-dialog = "2"
|
|
tauri-plugin-updater = "2.10.0"
|
|
tauri-plugin-process = "2.3.1"
|
|
tauri-plugin-opener = "2"
|
|
sentry = "0.37"
|
|
uuid = { version = "1", features = ["v4"] }
|
|
trash = "5"
|
|
|
|
[dev-dependencies]
|
|
tempfile = "3"
|
|
mockito = "1"
|