about summary refs log tree commit diff
path: root/Cargo.toml
diff options
context:
space:
mode:
authorVincent Ambo <mail@tazj.in>2019-02-26T12·49+0100
committerVincent Ambo <mail@tazj.in>2019-02-26T12·49+0100
commitc6c17464288848aba045d4dbd6ee06fb8925f1b9 (patch)
tree3fe812c1326ba51da4293ad8a02b901ebd962017 /Cargo.toml
parent479a6b3442a852d414d977cdfabf61ad8180d877 (diff)
refactor: Introduce `json` feature and make it optional
Gates support for `serde_json` behind a Cargo feature called `json`
that is enabled by default.
Diffstat (limited to 'Cargo.toml')
-rw-r--r--Cargo.toml8
1 files changed, 6 insertions, 2 deletions
diff --git a/Cargo.toml b/Cargo.toml
index 5f54546a39d5..60247f3e666e 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -3,7 +3,11 @@ name = "crimp"
 version = "0.1.0"
 authors = ["Vincent Ambo <mail@tazj.in>"]
 
+[features]
+default = [ "json" ]
+json = [ "serde", "serde_json"]
+
 [dependencies]
 curl = "0.4"
-serde = "1.0"
-serde_json = "1.0"
+serde = { version = "1.0", optional = true }
+serde_json = { version = "1.0", optional = true }