fif/Cargo.toml

90 lines
3 KiB
TOML
Raw Normal View History

2021-02-04 11:22:19 +00:00
[package]
name = "fif"
description = "A command-line tool for detecting and optionally correcting files with incorrect extensions."
2021-08-06 14:36:19 +00:00
version = "0.3.4"
2021-02-04 11:22:19 +00:00
authors = ["Lynnesbian <lynne@bune.city>"]
edition = "2018"
license = "GPL-3.0-or-later"
rust-version = "1.43.0" # cached breaks on 1.42.0, i think it needs https://github.com/rust-lang/rust/pull/67642/
2021-04-21 07:29:13 +00:00
repository = "https://gitlab.com/Lynnesbian/fif"
readme = "README.md"
keywords = ["mime", "mimetype", "utilities", "tools"]
categories = ["command-line-utilities"]
2021-04-27 08:34:01 +00:00
exclude = [".idea/", "*.toml", "!Cargo.toml", "*.sh", "*.py", "*.yml", "*.md", ".mailmap", "pkg/"]
#resolver = "2"
2021-02-05 06:05:33 +00:00
#license-file = "LICENSE"
2021-02-04 11:22:19 +00:00
2021-03-01 10:20:46 +00:00
[badges]
maintenance = { status = "experimental" }
[features]
2021-05-05 22:57:42 +00:00
default = ["multi-threaded", "json"]
multi-threaded = ["rayon"]
infer-backend = ["infer"]
xdg-mime-backend = ["xdg-mime"]
2021-05-05 22:57:42 +00:00
json = ["serde", "serde_json"]
2021-02-04 11:22:19 +00:00
[dependencies]
walkdir = "2.3.2"
2021-02-04 11:22:19 +00:00
log = "0.4.14"
mime = "0.3.16"
mime_guess = { package = "new_mime_guess", features = ["phf-map"], version = "3.0.0" }
snailquote = "0.3.0"
2021-06-14 06:53:41 +00:00
once_cell = "1.8.0"
rayon = { version = "1.5.0", optional = true }
2021-02-21 14:07:50 +00:00
exitcode = "1.1.2"
cfg-if = "1.0.0"
itertools = "0.10.0"
2021-05-05 22:57:42 +00:00
serde = { version = "1.0", features = ["derive"], optional = true }
serde_json = { version = "1.0", optional = true }
[target.'cfg(not(unix))'.dependencies]
xdg-mime = { version = "0.3.3", optional = true }
2021-06-07 05:21:47 +00:00
infer = "0.5.0"
[target.'cfg(unix)'.dependencies]
xdg-mime = "0.3.3"
2021-06-07 05:21:47 +00:00
infer = { version = "0.5.0", optional = true }
[target.'cfg(not(all(target_endian = "big", target_pointer_width = "32")))'.dependencies]
# the seemingly weird target constraint here is due to this:
# https://github.com/bodil/smartstring/blob/v0.2.7/src/config.rs#L102-L104
# essentially, smartstring is intentionally blocked from compiling on 32-bit big endian archs, so our dependency on it
# needs to be too. otherwise, fif won't work on platforms like powerpc, even though this dependency is the only
# blocker -- fif runs just fine on powerpc without smartstring. or at least, just fine under qemu user-mode powerpc ~u0
# additionally, smartstring 0.2.8 requires rust >=1.46 (due to https://github.com/rust-lang/rust/issues/49146), and
# 0.2.3 doesn't impl Display on its SmartString type.
# so, we need at least 0.2.4 so we can println! strings, and at most 0.2.7 until we bump the MSRV to at least 1.46.
# see https://github.com/bodil/smartstring/blob/master/CHANGELOG.md
smartstring = "<= 0.2.7, >= 0.2.4"
[dependencies.clap]
# beta.4 requires rust >= 1.54.0 (and beta.3 was yanked)
version = "=3.0.0-beta.2"
default-features = false
features = ["wrap_help", "color", "derive", "std"]
2021-02-05 13:34:02 +00:00
[dependencies.env_logger]
2021-08-03 05:27:03 +00:00
version = "0.9.0"
2021-02-05 13:34:02 +00:00
default-features = false
features = ["termcolor", "atty"]
[dependencies.cached]
2021-08-03 05:27:03 +00:00
version = "0.24.0"
default-features = false
[dev-dependencies]
tempfile = "3.2.0"
rand = "0.8.3"
2021-02-05 13:34:02 +00:00
[profile.release]
lto = "thin"
# optimise dependencies, even when producing debug and test builds
[profile.dev.package."*"]
opt-level = 3
[profile.test.package."*"]
opt-level = 3