mirror of
https://github.com/cargo-bins/cargo-binstall.git
synced 2025-04-24 14:28:42 +00:00
fix: use custom DNS resolver (#1364)
* add DefaultResolver * style: fmt * chore: remove unused feature Co-authored-by: Jiahao XU <Jiahao_XU@outlook.com> * chore: remove unused `ipconfig/computer` feature Co-authored-by: Jiahao XU <Jiahao_XU@outlook.com> * chore: update `trust-dns-resolver` * refactor: apply requested changes * chore: revert `trust-dns-resolver` upgrade I mistakenly thought `reqwest` already updated to the newest version, but it hasn't! (no release was made yet) * refactor: cleanup --------- Co-authored-by: GNQG <my.t.gnq+dev@gmail.com> Co-authored-by: Jiahao XU <Jiahao_XU@outlook.com>
This commit is contained in:
parent
04c5c00669
commit
6560225c03
5 changed files with 196 additions and 2 deletions
|
@ -37,7 +37,9 @@ tokio-tar = "0.3.0"
|
|||
tokio-util = { version = "0.7.8", features = ["io"] }
|
||||
tracing = "0.1.37"
|
||||
# trust-dns-resolver must be kept in sync with the version reqwest uses
|
||||
trust-dns-resolver = { version = "0.22.0", optional = true, default-features = false, features = ["dnssec-ring"] }
|
||||
trust-dns-resolver = { version = "0.22.0", optional = true, features = ["dnssec-ring"] }
|
||||
hyper = { version = "0.14.27", optional = true }
|
||||
once_cell = { version = "1.18.0", optional = true }
|
||||
url = "2.3.1"
|
||||
|
||||
xz2 = "0.1.7"
|
||||
|
@ -78,7 +80,7 @@ native-tls = [
|
|||
]
|
||||
|
||||
# Enable trust-dns-resolver so that features on it will also be enabled.
|
||||
trust-dns = ["trust-dns-resolver", "reqwest/trust-dns"]
|
||||
trust-dns = ["trust-dns-resolver", "default-net", "ipconfig", "hyper", "once_cell"]
|
||||
|
||||
# Experimental HTTP/3 client, this would require `--cfg reqwest_unstable`
|
||||
# to be passed to `rustc`.
|
||||
|
@ -91,6 +93,10 @@ cross-lang-fat-lto = ["zstd/fat-lto"]
|
|||
gh-api-client = ["json"]
|
||||
json = ["serde", "serde_json"]
|
||||
|
||||
[target."cfg(windows)".dependencies]
|
||||
default-net = { version = "0.17.0", optional = true }
|
||||
ipconfig = { version = "0.3.2", optional = true, default-features = false }
|
||||
|
||||
[package.metadata.docs.rs]
|
||||
features = ["gh-api-client"]
|
||||
rustdoc-args = ["--cfg", "docsrs"]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue