mirror of
https://github.com/cargo-bins/cargo-binstall.git
synced 2025-04-22 13:38:43 +00:00

* Refactor: Extract new crate binstalk-types * Optimize: Rm field `CrateInfo::other` which also removes dep serde-tuple-vec-map and serde-json from binstalk-types. This also makes `CrateInfo` easier to use, more generic and can be used over any `Serializer`, not just `serde_json::Value`. * Mark all errors in `binstalk-manifests` as non_exhaustive * Reduce size of `CvsParseError` by using `Box<str>` instead of `String` for variant `UnknownSourceType`. * Reduce size of `CratesTomlParseError` to 16 bytes on 64bit platform by boxing variants `TomlWrite` and `CvsParse` as these two fields are significantly larger than other variants. * Unify import style in mod `binstall_crates_v1` * Replace dep binstalk-manifests with binstalk-types in binstalk-downloader to reduce its transitive dependencies and enables binstalk-downloader to be built in parallel to binstak-manifests. * Replace dep binstalk-manifests with binstalk-types in binstalk to reduce transitive dependencies and enables binstalk to be built in parallel to binstalk-manifests. This is benefitial because binstalk-manifests pulls in toml_edit, which could takes up to 15s to be built on M1 (7-9s for codegen). * Add dep binstalk-manifests to crates/bin * Update dependabot and GHA release-pr Signed-off-by: Jiahao XU <Jiahao_XU@outlook.com>
70 lines
2.5 KiB
TOML
70 lines
2.5 KiB
TOML
[package]
|
|
name = "binstalk-downloader"
|
|
description = "The binstall toolkit for downloading and extracting file"
|
|
repository = "https://github.com/cargo-bins/cargo-binstall"
|
|
documentation = "https://docs.rs/binstalk-downloader"
|
|
version = "0.1.0"
|
|
rust-version = "1.61.0"
|
|
authors = ["ryan <ryan@kurte.nz>"]
|
|
edition = "2021"
|
|
license = "GPL-3.0"
|
|
|
|
[dependencies]
|
|
binstalk-types = { version = "0.1.0", path = "../binstalk-types" }
|
|
bytes = "1.2.1"
|
|
bzip2 = "0.4.3"
|
|
digest = "0.10.5"
|
|
flate2 = { version = "1.0.24", default-features = false }
|
|
futures-util = { version = "0.3.25", default-features = false, features = ["std"] }
|
|
generic-array = "0.14.6"
|
|
httpdate = "1.0.2"
|
|
reqwest = { version = "0.11.12", features = ["stream", "gzip", "brotli", "deflate"], default-features = false }
|
|
scopeguard = "1.1.0"
|
|
# Use a fork here since we need PAX support, but the upstream
|
|
# does not hav the PR merged yet.
|
|
#
|
|
#tar = "0.4.38"
|
|
tar = { package = "binstall-tar", version = "0.4.39" }
|
|
tempfile = "3.3.0"
|
|
thiserror = "1.0.37"
|
|
tokio = { version = "1.21.2", features = ["macros", "rt-multi-thread", "sync", "time"], default-features = false }
|
|
tower = { version = "0.4.13", features = ["limit", "util"] }
|
|
tracing = "0.1.37"
|
|
trust-dns-resolver = { version = "0.21.2", optional = true, default-features = false, features = ["dnssec-ring"] }
|
|
url = "2.3.1"
|
|
|
|
xz2 = "0.1.7"
|
|
|
|
# Disable all features of zip except for features of compression algorithms:
|
|
# Disabled features include:
|
|
# - aes-crypto: Enables decryption of files which were encrypted with AES, absolutely zero use for
|
|
# this crate.
|
|
# - time: Enables features using the [time](https://github.com/time-rs/time) crate,
|
|
# which is not used by this crate.
|
|
zip = { version = "0.6.3", default-features = false, features = ["deflate", "bzip2", "zstd"] }
|
|
|
|
# zstd is also depended by zip.
|
|
# Since zip 0.6.3 depends on zstd 0.11, we also have to use 0.11 here,
|
|
# otherwise there will be a link conflict.
|
|
zstd = { version = "0.11.2", default-features = false }
|
|
|
|
[features]
|
|
default = ["static", "rustls"]
|
|
|
|
static = ["bzip2/static", "xz2/static"]
|
|
pkg-config = ["zstd/pkg-config"]
|
|
|
|
zlib-ng = ["flate2/zlib-ng"]
|
|
|
|
rustls = [
|
|
"reqwest/rustls-tls",
|
|
|
|
# Enable the following features only if trust-dns-resolver is enabled.
|
|
"trust-dns-resolver?/dns-over-rustls",
|
|
# trust-dns-resolver currently supports https with rustls
|
|
"trust-dns-resolver?/dns-over-https-rustls",
|
|
]
|
|
native-tls = ["reqwest/native-tls", "trust-dns-resolver?/dns-over-native-tls"]
|
|
|
|
# Enable trust-dns-resolver so that features on it will also be enabled.
|
|
trust-dns = ["trust-dns-resolver", "reqwest/trust-dns"]
|