aboutsummaryrefslogtreecommitdiff
path: root/Cargo.toml
diff options
context:
space:
mode:
authorMartin Fischer <martin@push-f.com>2021-04-09 12:32:01 +0200
committerMartin Fischer <martin@push-f.com>2021-04-09 12:49:02 +0200
commit9df4a6c0b55b2e680eca4e89489ad4c684bfb127 (patch)
tree9d95f03bd52509bb29b76ad9ed21f3d796272619 /Cargo.toml
parentbfeddf5d15ddaa9937ceeba04678ad6c4a4e8aea (diff)
make hyper dependency optional
Diffstat (limited to 'Cargo.toml')
-rw-r--r--Cargo.toml13
1 files changed, 8 insertions, 5 deletions
diff --git a/Cargo.toml b/Cargo.toml
index f28c39b..cc9e454 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -3,19 +3,20 @@ name = "sputnik"
version = "0.3.6"
authors = ["Martin Fischer <martin@push-f.com>"]
license = "MIT"
-description = "A lightweight layer on top of hyper to facilitate building web applications."
+description = "Extends the types from the http crate with methods to deal with cookies/content-types (and optionally adds deserialization methods to hyper::Body)."
repository = "https://git.push-f.com/sputnik"
edition = "2018"
categories = ["web-programming::http-server"]
-keywords = ["hyper", "web", "cookie", "hmac"]
+keywords = ["web", "cookie", "hyper", "hmac"]
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[features]
-json = ["serde_json"]
+hyper_body = ["hyper", "async-trait"]
+hyper_body_json = ["serde_json", "hyper_body"]
[dependencies]
-hyper = "0.14"
+http = "0.2"
cookie = { version = "0.15", features = ["percent-encode"] }
serde = { version = "1.0", features = ["derive"] }
serde_urlencoded = "0.7.0"
@@ -27,7 +28,9 @@ rand = "0.8"
sha2 = "0.9"
time = "0.2"
thiserror = "1.0"
-async-trait = "0.1"
+
+hyper = { version = "0.14", optional = true }
+async-trait = { version = "0.1", optional = true }
serde_json = { version = "1.0", optional = true }
[package.metadata.docs.rs]