-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCargo.toml
More file actions
99 lines (94 loc) · 4.49 KB
/
Copy pathCargo.toml
File metadata and controls
99 lines (94 loc) · 4.49 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
[workspace]
members = [
"apps/rocm",
"apps/rocmd",
"crates/rocm-core",
"crates/rocm-engine-protocol",
# rocm-dash telemetry/dashboard libraries (rocm-dash merge).
"crates/rocm-dash-core",
"crates/rocm-dash-collectors",
"crates/rocm-dash-daemon",
"crates/rocm-dash-tui",
"engines/lemonade",
"engines/vllm",
"xtask",
]
resolver = "2"
[workspace.package]
version = "0.3.0"
edition = "2024"
license = "MIT"
repository = "https://github.com/ROCm/rocm-cli"
rust-version = "1.96"
# First-party crates are an application, not crates.io libraries: never publish
# them. This also keeps them out of THIRD_PARTY_NOTICES.txt (cargo-about's
# `private.ignore`). Members opt in with `publish.workspace = true`.
publish = false
[workspace.dependencies]
anyhow = "1.0"
async-stream = "0.3"
axum = "0.8"
clap = { version = "4.6", features = ["derive", "string", "suggestions"] }
clap_complete = "4.6"
crossterm = { version = "0.29", features = ["libc", "use-dev-tty"] }
directories = "6.0"
keyring-core = "1.0.0"
libc = "0.2"
rand = "0.8"
ratatui = { version = "0.29", features = ["unstable-rendered-line-info"] }
rpassword = "7.5"
rsa = "0.9"
semver = "1.0"
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
sha2 = { version = "0.10", features = ["oid"] }
tokio = { version = "1.48", features = ["macros", "net", "rt-multi-thread", "signal", "sync", "time"] }
[workspace.lints.rust]
# `deny` (not `forbid`) so the few functions doing platform FFI can opt back in
# with a documented `#[allow(unsafe_code)]`; everything else is denied.
# (`unreachable_pub` is intentionally NOT enabled: this workspace is dominated by
# binary crates where every `pub` item is unreachable, so it only adds noise.)
unsafe_code = "deny"
# Strictest *practical* clippy config. Lint groups are enabled at warn with a
# lowered priority so the targeted `allow`s below win. CI promotes warnings to
# errors via `cargo clippy ... -D warnings`.
[workspace.lints.clippy]
all = { level = "warn", priority = -1 }
pedantic = { level = "warn", priority = -1 }
nursery = { level = "warn", priority = -1 }
# Documented allow-list: high-noise / low-value lints whose findings would force
# large, mechanical, or risky churn for little benefit on this codebase. Each is
# centralized here so it can be re-enabled and burned down later.
#
# Docs / naming / metadata churn:
missing_errors_doc = "allow" # would require `# Errors` docs on every fallible fn
missing_panics_doc = "allow" # would require `# Panics` docs on every fn that can panic
must_use_candidate = "allow" # `#[must_use]` on every getter-style fn is noise here
too_many_lines = "allow" # long fns (TUI/install flows) are deliberate, not split-worthy
module_name_repetitions = "allow" # `engine::EngineConfig` naming is intentional and clear
doc_markdown = "allow" # flags product names (ROCm, GPU ids) as needing backticks
similar_names = "allow" # short domain names (gfx/gpu, src/dst) are intentionally alike
struct_excessive_bools = "allow" # flat config/probe-result records use bool fields by design
multiple_crate_versions = "allow" # unactionable: duplicate versions come from transitive deps
cargo_common_metadata = "allow" # internal-only crates don't need description/keywords
#
# Signature/API churn (changing these ripples through many call sites for little gain):
needless_pass_by_value = "allow" # taking `&T` everywhere would churn many signatures + callers
trivially_copy_pass_by_ref = "allow" # mirror of the above for small Copy types
unnecessary_wraps = "allow" # several fns keep `Result`/`Option` for API consistency
#
# Deliberate numeric casts (values are known-in-range; `as` is intentional here):
cast_possible_truncation = "allow"
cast_sign_loss = "allow"
cast_precision_loss = "allow"
#
# Nursery lints (still unstable / frequently reduce readability or are micro-opts):
assigning_clones = "allow" # `clone_into` micro-opt across 500+ sites; not worth the churn
option_if_let_else = "allow" # the rewrite is often less readable than the `if let`
branches_sharing_code = "allow" # hoisting shared branch code often hurts clarity
significant_drop_tightening = "allow" # lock-scope rewrites are subtle; opt in deliberately
redundant_pub_crate = "allow" # `pub(crate)` in private modules is intentional/harmless here
useless_let_if_seq = "allow" # has false positives; several flags are set across multiple `if`s
#
# Style preference: explicit match arms are clearer than merging here.
match_same_arms = "allow"