Files
xop/Cargo.toml
xop-botandClaude Code 42b4512663 chore: 关闭 dev profile 增量编译 + 补齐 Cargo.toml 末尾换行
影响:
- 本地 `cargo build` 不再生成 target/debug/incremental 缓存目录,磁盘占用明显下降
- 改完源码必须全量重编(首次约 30s),换来 sccache 命中率提升与构建产物可控

改动:
- Cargo.toml 增加 `[profile.dev] incremental = false`,让 workspace member 正常进入 sccache 缓存
- 补齐文件末尾换行,消除 git 的 "\ No newline at end of file" 噪声

Co-Authored-By: Claude Code <[email protected]>
2026-11-09 18:46:30 +08:00

107 lines
2.7 KiB
TOML

[package]
name = "xop"
version = "0.5.2"
edition = "2021"
description = "Local encrypted secret vault with Touch ID/PAM auth and optional child-process injection"
license = "MIT"
repository = "https://github.com/your-org/xop"
keywords = ["secrets", "vault", "cli", "credential-injection", "touch-id", "pam"]
categories = ["command-line-utilities", "authentication", "cryptography"]
[lib]
name = "xop"
path = "src/lib.rs"
[[bin]]
name = "xop"
path = "src/main.rs"
[dependencies]
# CLI
clap = { version = "4", features = ["derive", "env"] }
# Async runtime
tokio = { version = "1", features = ["full"] }
# Error handling
anyhow = "1"
thiserror = "2"
# Serialization (audit log / config)
serde = { version = "1", features = ["derive"] }
serde_json = "1"
# Secret type hygiene
secrecy = "0.10"
# Process / POSIX
nix = { version = "0.29", features = ["process", "signal", "fs", "net", "resource"] }
# Random number generation (vault salt/nonce)
rand = "0.8"
# Regex (argv parsing, stdout masking)
regex = "1"
# Time (audit log timestamps)
chrono = { version = "0.4", features = ["serde"] }
# Logging
tracing = "0.1"
tracing-subscriber = { version = "0.3", features = ["env-filter", "json"] }
# Async trait support (required for `async fn` in traits used as dyn)
async-trait = "0.1"
# Backend discovery (used by exec mode for resolving PATH)
which = "6"
# Templating
once_cell = "1"
# ── v0.2: local vault + auth ─────────────────────────────────────────────────
# Crypto for vault
aes-gcm = "0.10"
argon2 = "0.5"
zeroize = { version = "1", features = ["zeroize_derive"] }
# Vault plaintext format
toml = "0.8"
# Hidden passphrase prompt
rpassword = "7"
# Filesystem locking for atomic vault writes
fs2 = "0.4"
# Linux: PAM auth (currently uses pkexec subprocess; pam crate optional for future)
# [target.'cfg(target_os = "linux")'.dependencies]
# pam = "0.8"
# macOS: Touch ID via LAContext
[target.'cfg(target_os = "macos")'.dependencies]
cocoa = "0.26"
objc = "0.2"
[dev-dependencies]
assert_cmd = "2"
predicates = "3"
tempfile = "3"
serial_test = "3"
# Test-only feature: when enabled, `xop` will read `XOP_VAULT_PASSWORD` from
# the environment as a substitute for the interactive /dev/tty passphrase prompt.
# Used solely by `cargo test --features test-bypass` so integration tests
# can drive the binary non-interactively. NEVER enabled in release builds —
# shipping it would let any process with the env var bypass the entire
# passphrase layer and defeat the point of the encrypted vault.
[features]
default = []
test-bypass = []
[profile.release]
opt-level = 3
lto = "thin"
codegen-units = 1
strip = true
[profile.dev]
incremental = false