Repository navigation
Expand file tree
/
Copy pathCargo.toml
More file actions
100 lines (88 loc) · 3.1 KB
/
Copy pathCargo.toml
File metadata and controls
100 lines (88 loc) · 3.1 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
[package]
name = "git-metadata"
version = "0.4.1"
edition = "2024"
publish = true
readme = "README.md"
license = "MIT OR Apache-2.0"
description = "Porcelain for adding metadata to any git object without rewriting history."
repository = "https://github.com/git-ents/git-metadata"
homepage = "https://github.com/git-ents/git-metadata"
documentation = "https://docs.rs/git-metadata"
include = ["src/**/*", "LICENSE-*", "README.md", "CHANGELOG.md", "!**/tests/**/*"]
[[bin]]
name = "git-metadata"
path = "src/main.rs"
required-features = ["cli"]
[features]
default = ["cli"]
cli = ["dep:anyhow", "dep:clap", "dep:clap_mangen", "dep:edit", "dep:termtree"]
[dependencies]
anyhow = { version = "1.0.102", optional = true }
clap = { version = "4.5.60", features = ["derive"], optional = true }
clap_mangen = { version = "0.2.31", optional = true }
edit = { version = "0.1.5", optional = true }
termtree = { version = "0.4", optional = true }
gix = { version = "0.83.0", features = ["tree-editor", "merge"] }
thiserror = "2.0.18"
[dev-dependencies]
gix = { version = "0.83.0", features = ["sha256"] }
proptest = "1.5.0"
rstest = "0.23.0"
tempfile = "3.27.0"
# These lint configurations were originally pulled from [Evan Schwartz][1].
# [1]: https://emschwartz.me/your-clippy-config-should-be-stricter/
[workspace.lints.clippy]
# Don't Panic - prevent panics from unwraps and unsafe slicing or indexing
string_slice = "warn"
indexing_slicing = "warn"
unwrap_used = "warn"
panic = "warn"
todo = "warn"
unimplemented = "warn"
unreachable = "warn"
get_unwrap = "warn"
unwrap_in_result = "warn"
unchecked_time_subtraction = "warn"
panic_in_result_fn = "warn"
# Optional - see post for caveats
# expect_used = "warn"
# arithmetic_side_effects = "warn"
# Don't Fail Silently - prevent dropped futures and swallowed errors
let_underscore_future = "warn"
let_underscore_must_use = "warn"
unused_result_ok = "warn"
map_err_ignore = "warn"
assertions_on_result_states = "warn"
# Don't Do Bad Async Stuff - prevent deadlocks and concurrency bugs
await_holding_lock = "warn"
await_holding_refcell_ref = "warn"
if_let_mutex = "warn" # only relevant on editions before 2024
large_futures = "warn"
# Don't Do Unsafe Things with Memory
mem_forget = "warn"
undocumented_unsafe_blocks = "warn"
multiple_unsafe_ops_per_block = "warn"
unnecessary_safety_doc = "warn"
unnecessary_safety_comment = "warn"
# Don't Do Potentially Incorrect Things with Numbers
float_cmp = "warn"
float_cmp_const = "warn"
lossy_float_literal = "warn"
cast_sign_loss = "warn"
invalid_upcast_comparisons = "warn"
# Optional - these effectively force you to document numeric invariants
# cast_possible_wrap = "warn"
# cast_precision_loss = "warn"
# cast_possible_truncation = "warn"
# Don't Do Bad Things That are Easy to Avoid
rc_mutex = "warn"
debug_assert_with_mut_call = "warn"
iter_not_returning_iterator = "warn"
expl_impl_clone_on_copy = "warn"
infallible_try_from = "warn"
dbg_macro = "warn"
# Don't `allow` Your Way Around These Lints - every suppression must be
# a deliberate #[expect(..., reason = "…")] rather than a silent #[allow]
allow_attributes = "warn"
allow_attributes_without_reason = "warn"