-
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathCargo.toml
More file actions
146 lines (126 loc) · 4.66 KB
/
Copy pathCargo.toml
File metadata and controls
146 lines (126 loc) · 4.66 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
[package]
name = "opaline"
version = "0.4.1"
edition = "2024"
rust-version = "1.85"
authors = ["Stefanie Jane <stef@hyperbliss.tech>"]
description = "A token-based theme engine for Rust applications"
readme = "README.md"
homepage = "https://github.com/hyperb1iss/opaline"
repository = "https://github.com/hyperb1iss/opaline"
license = "MIT"
keywords = ["theme", "color", "tui", "terminal", "egui"]
categories = ["command-line-interface", "config", "gui"]
[lib]
name = "opaline"
path = "src/lib.rs"
[features]
default = ["builtin-themes", "gradients", "ratatui"]
builtin-themes = []
gradients = ["dep:unicode-segmentation"]
global-state = ["dep:parking_lot"]
discovery = ["dep:dirs"]
ratatui = ["dep:ratatui-core"]
widgets = [
"dep:ratatui",
"dep:crossterm",
"dep:unicode-width",
"ratatui",
"global-state",
"builtin-themes",
]
cli = ["dep:colored"]
css = []
crossterm = ["dep:crossterm"]
owo-colors = ["dep:owo-colors"]
syntect = ["dep:syntect"]
egui = ["dep:egui"]
iced = ["dep:iced_core"]
[dependencies]
thiserror = "2.0"
serde = { version = "1", features = ["derive"] }
toml = "0.8"
unicode-segmentation = { version = "1.12", optional = true }
unicode-width = { version = "0.2.2", optional = true }
ratatui-core = { version = "0.1", optional = true }
ratatui = { version = "0.30", optional = true, default-features = false, features = ["crossterm"] }
crossterm = { version = "0.29", optional = true }
parking_lot = { version = "0.12", optional = true }
dirs = { version = "6", optional = true }
colored = { version = "3", optional = true }
owo-colors = { version = "4", optional = true }
syntect = { version = "5", optional = true, default-features = false }
egui = { version = "0.33", optional = true, default-features = false }
iced_core = { version = "0.14", optional = true }
[dev-dependencies]
pretty_assertions = "1"
serde_json = "1.0.149"
crossterm = "0.29"
ratatui = "0.30"
[[example]]
name = "theme-showcase"
path = "examples/theme_showcase.rs"
required-features = ["builtin-themes", "gradients", "ratatui"]
[profile.release]
lto = true
codegen-units = 1
strip = true
[package.metadata.docs.rs]
all-features = true
rustdoc-args = ["--cfg", "docsrs"]
[lints.rust]
unsafe_code = "forbid"
missing_docs = { level = "allow", priority = 1 }
[lints.clippy]
# Base groups
all = { level = "deny", priority = 0 }
style = { level = "warn", priority = 1 }
perf = { level = "deny", priority = 1 }
pedantic = { level = "deny", priority = 10 }
# Documentation — relaxed
missing_errors_doc = { level = "allow", priority = 20 }
missing_panics_doc = { level = "allow", priority = 20 }
missing_safety_doc = { level = "allow", priority = 20 }
# Pragmatic style allowances
module_name_repetitions = { level = "allow", priority = 21 }
significant_drop_tightening = { level = "allow", priority = 21 }
must_use_candidate = { level = "allow", priority = 21 }
# Numeric casting — warn not deny
cast_precision_loss = { level = "warn", priority = 22 }
cast_possible_truncation = { level = "warn", priority = 22 }
cast_sign_loss = { level = "warn", priority = 22 }
as_conversions = { level = "warn", priority = 22 }
# Safety-critical — hard deny
out_of_bounds_indexing = { level = "deny", priority = 30 }
enum_glob_use = { level = "deny", priority = 30 }
unwrap_used = { level = "deny", priority = 30 }
undocumented_unsafe_blocks = { level = "deny", priority = 30 }
# Debug artifacts
dbg_macro = { level = "warn", priority = 31 }
todo = { level = "warn", priority = 31 }
# Async-specific
future_not_send = { level = "warn", priority = 32 }
async_yields_async = { level = "warn", priority = 32 }
# String/collection efficiency
implicit_clone = { level = "warn", priority = 33 }
inefficient_to_string = { level = "warn", priority = 33 }
string_lit_as_bytes = { level = "warn", priority = 33 }
# Complexity
too_many_lines = { level = "warn", priority = 34 }
cognitive_complexity = { level = "warn", priority = 34 }
# Error handling
result_large_err = { level = "warn", priority = 35 }
# Modern Rust idioms
manual_let_else = { level = "warn", priority = 36 }
redundant_else = { level = "warn", priority = 36 }
semicolon_if_nothing_returned = { level = "warn", priority = 36 }
cloned_instead_of_copied = { level = "warn", priority = 36 }
flat_map_option = { level = "warn", priority = 36 }
from_iter_instead_of_collect = { level = "warn", priority = 36 }
needless_pass_by_value = { level = "warn", priority = 36 }
trivially_copy_pass_by_ref = { level = "warn", priority = 36 }
if_not_else = { level = "warn", priority = 36 }
match_same_arms = { level = "warn", priority = 36 }
needless_continue = { level = "warn", priority = 36 }
# Allow transitive dependency version conflicts
multiple_crate_versions = { level = "allow", priority = 40 }