-
-
Notifications
You must be signed in to change notification settings - Fork 25
/
Cargo.toml
86 lines (78 loc) · 3.53 KB
/
Cargo.toml
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
[package]
name = "twitch-irc"
description = "Connect to Twitch chat from a Rust application."
license = "MIT"
version = "5.0.1"
authors = ["Ruben Anders <[email protected]>"]
keywords = ["twitch", "twitch-irc", "twitch-api"]
categories = ["api-bindings", "asynchronous", "network-programming", "parser-implementations"]
repository = "https://github.com/robotty/twitch-irc-rs"
edition = "2021"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
# https://docs.rs/about/metadata
[package.metadata.docs.rs]
# If updating this make sure to update workflows/rust.yml too
features = [
"refreshing-token-rustls-webpki-roots",
"transport-tcp",
"transport-tcp-rustls-webpki-roots",
"transport-ws",
"transport-ws-rustls-webpki-roots",
"metrics-collection",
"with-serde"
]
no-default-features = true
[dependencies]
async-trait = "0.1"
async-tungstenite = { version = "0.23", features = ["tokio-runtime"], optional = true }
bytes = { version = "1", optional = true }
chrono = { version = "0.4", default-features = false }
either = "1"
enum_dispatch = "0.3"
futures-util = { version = "0.3", default-features = false, features = ["async-await", "sink", "std"] }
prometheus = { version = "0.13", default-features = false, optional = true }
reqwest = { version = "0.11", default-features = false, features = ["json"], optional = true }
rustls-native-certs = { version = "0.6", optional = true }
serde = { version = "1", features = ["derive"], optional = true }
smallvec = "1"
thiserror = "1"
tokio = { version = "1", features = ["rt", "time", "sync", "macros"] }
tokio-native-tls = { version = "0.3", optional = true }
tokio-rustls = { version = "0.24", optional = true }
tokio-stream = { version = "0.1", features = ["io-util"], optional = true }
tokio-util = { version = "0.7", features = ["codec"], optional = true }
tracing = "0.1"
webpki-roots = { version = "0.25", optional = true }
[dev-dependencies]
maplit = "1"
serde_json = "1"
tokio = { version = "1", features = ["rt-multi-thread"] }
tracing-subscriber = "0.3"
# For the metrics example
axum = "0.6"
[lib]
name = "twitch_irc"
path = "src/lib.rs"
[[example]]
name = "simple_listener"
required-features = ["transport-tcp", "transport-tcp-native-tls"]
[[example]]
name = "metrics"
required-features = ["transport-tcp", "transport-tcp-native-tls", "metrics-collection"]
[features]
# If you add a feature here don't forget to add it to the test workflow in workflows/rust.yml!
default = ["transport-tcp", "transport-tcp-native-tls"]
refreshing-token-native-tls = ["reqwest/native-tls", "__refreshing-token"]
refreshing-token-rustls-native-roots = ["reqwest/rustls-tls-native-roots", "__refreshing-token"]
refreshing-token-rustls-webpki-roots = ["reqwest/rustls-tls-webpki-roots", "__refreshing-token"]
__refreshing-token = ["with-serde", "chrono/clock"]
transport-tcp = ["bytes", "tokio/net", "tokio/io-util", "tokio-util", "tokio-stream"]
transport-tcp-native-tls = ["transport-tcp", "tokio-native-tls"]
transport-tcp-rustls-native-roots = ["transport-tcp", "tokio-rustls", "rustls-native-certs"]
transport-tcp-rustls-webpki-roots = ["transport-tcp", "tokio-rustls", "webpki-roots"]
transport-ws = ["async-tungstenite", "tokio-util"]
transport-ws-native-tls = ["transport-ws", "async-tungstenite/tokio-native-tls"]
transport-ws-rustls-native-roots = ["transport-ws", "async-tungstenite/tokio-rustls-native-certs"]
transport-ws-rustls-webpki-roots = ["transport-ws", "async-tungstenite/tokio-rustls-webpki-roots"]
metrics-collection = ["prometheus"]
with-serde = ["serde", "chrono/serde"]