aboutsummaryrefslogtreecommitdiff
path: root/Cargo.toml
diff options
context:
space:
mode:
authorMathijs van Veluw <[email protected]>2024-02-08 22:16:29 +0100
committerGitHub <[email protected]>2024-02-08 22:16:29 +0100
commitb9bdc9b8e227b556e6744c675a259b29d9e277db (patch)
tree203c5bf594ad5dff46c4210c5433f49566cc7276 /Cargo.toml
parent897bdf8343148ee4e4f1a937cbc501ad3f743b4a (diff)
downloadvaultwarden-b9bdc9b8e227b556e6744c675a259b29d9e277db.tar.gz
vaultwarden-b9bdc9b8e227b556e6744c675a259b29d9e277db.zip
Update Rust, crates and web-vault (#4328)
- Updated Rust to v1.76.0 - Updated crates - Updated web-vault to v2024.1.2b - Fixed some Clippy lints - Moved lint check configuration Cargo.toml - Fixed issue with Reset Password Enrollment when logged-in via device
Diffstat (limited to 'Cargo.toml')
-rw-r--r--Cargo.toml65
1 files changed, 61 insertions, 4 deletions
diff --git a/Cargo.toml b/Cargo.toml
index b0db92a4..5f07f1a7 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -3,7 +3,7 @@ name = "vaultwarden"
version = "1.0.0"
authors = ["Daniel GarcĂ­a <[email protected]>"]
edition = "2021"
-rust-version = "1.73.0"
+rust-version = "1.74.0"
resolver = "2"
repository = "https://github.com/dani-garcia/vaultwarden"
@@ -51,8 +51,8 @@ dotenvy = { version = "0.15.7", default-features = false }
once_cell = "1.19.0"
# Numerical libraries
-num-traits = "0.2.17"
-num-derive = "0.4.1"
+num-traits = "0.2.18"
+num-derive = "0.4.2"
bigdecimal = "0.4.2"
# Web framework
@@ -92,7 +92,7 @@ uuid = { version = "1.7.0", features = ["v4"] }
# Date and time libraries
chrono = { version = "0.4.33", features = ["clock", "serde"], default-features = false }
chrono-tz = "0.8.5"
-time = "0.3.32"
+time = "0.3.34"
# Job scheduler
job_scheduler_ng = "2.0.4"
@@ -190,3 +190,60 @@ strip = "symbols"
lto = "fat"
codegen-units = 1
panic = "abort"
+
+# Profile for systems with low resources
+# It will use less resources during build
+[profile.release-low]
+inherits = "release"
+strip = "symbols"
+lto = "thin"
+codegen-units = 1
+
+# Linting config
+[lints.rust]
+# Forbid
+unsafe_code = "forbid"
+non_ascii_idents = "forbid"
+
+# Deny
+future_incompatible = "deny"
+noop_method_call = "deny"
+pointer_structural_match = "deny"
+rust_2018_idioms = "deny"
+rust_2021_compatibility = "deny"
+trivial_casts = "deny"
+trivial_numeric_casts = "deny"
+unused = "deny"
+unused_import_braces = "deny"
+unused_lifetimes = "deny"
+deprecated_in_future = "deny"
+
+[lints.clippy]
+# Allow
+# We need this since Rust v1.76+, since it has some bugs
+# https://github.com/rust-lang/rust-clippy/issues/12016
+blocks_in_conditions = "allow"
+
+# Deny
+cast_lossless = "deny"
+clone_on_ref_ptr = "deny"
+equatable_if_let = "deny"
+float_cmp_const = "deny"
+inefficient_to_string = "deny"
+iter_on_empty_collections = "deny"
+iter_on_single_items = "deny"
+linkedlist = "deny"
+macro_use_imports = "deny"
+manual_assert = "deny"
+manual_instant_elapsed = "deny"
+manual_string_new = "deny"
+match_wildcard_for_single_variants = "deny"
+mem_forget = "deny"
+needless_lifetimes = "deny"
+string_add_assign = "deny"
+string_to_string = "deny"
+unnecessary_join = "deny"
+unnecessary_self_imports = "deny"
+unused_async = "deny"
+verbose_file_reads = "deny"
+zero_sized_map_values = "deny"