92 lines
No EOL
3 KiB
TOML
92 lines
No EOL
3 KiB
TOML
[package]
|
|
name = "fif"
|
|
description = "A command-line tool for detecting and optionally correcting files with incorrect extensions."
|
|
version = "0.3.6"
|
|
authors = ["Lynnesbian <lynne@bune.city>"]
|
|
edition = "2021"
|
|
license = "GPL-3.0-or-later"
|
|
rust-version = "1.56.0"
|
|
repository = "https://gitlab.com/Lynnesbian/fif"
|
|
readme = "README.md"
|
|
keywords = ["mime", "mimetype", "utilities", "tools"]
|
|
categories = ["command-line-utilities"]
|
|
exclude = [".idea/", "*.toml", "!Cargo.toml", "*.sh", "*.py", "*.yml", "*.md", ".mailmap", "pkg/"]
|
|
|
|
# unfortunately, we can't use resolver v2 right now, because one of the phf crates (i think it's phf_codegen) that are
|
|
# pulled in by new_mime_guess' phf-map feature doesn't enable phf_shared's unicase feature when it should.
|
|
# this causes new_mime_guess' build.rs to fail with errors about PhfHash traits and such not being implemented for
|
|
# UniCase<&str>.
|
|
# there's no way to fix this in either fif or new_mime_guess itself, short of a patch (which can't be used on
|
|
# crates.io), so we'll have to disable the new resolver for now :(
|
|
resolver = "1"
|
|
|
|
[badges]
|
|
maintenance = { status = "experimental" }
|
|
|
|
[features]
|
|
default = ["multi-threaded", "json"]
|
|
multi-threaded = ["rayon"]
|
|
infer-backend = ["infer"]
|
|
xdg-mime-backend = ["xdg-mime"]
|
|
json = ["serde", "serde_json"]
|
|
|
|
[dependencies]
|
|
walkdir = "~2.3.2"
|
|
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"
|
|
once_cell = "1.8.0"
|
|
rayon = { version = "1.5.0", optional = true }
|
|
exitcode = "1.1.2"
|
|
cfg-if = "1.0.0"
|
|
itertools = "0.10.0"
|
|
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 }
|
|
infer = "0.5.0"
|
|
|
|
[target.'cfg(unix)'.dependencies]
|
|
xdg-mime = "0.3.3"
|
|
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.9/src/config.rs#L91-L93
|
|
# 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
|
|
smartstring = "0.2.9"
|
|
|
|
[dependencies.clap]
|
|
version = "=3.0.0-beta.4"
|
|
default-features = false
|
|
features = ["wrap_help", "color", "derive", "std"]
|
|
|
|
[dependencies.env_logger]
|
|
version = "0.9.0"
|
|
default-features = false
|
|
features = ["termcolor", "atty"]
|
|
|
|
[dependencies.cached]
|
|
version = "0.25.0"
|
|
default-features = false
|
|
|
|
[dev-dependencies]
|
|
tempfile = "3.2.0"
|
|
rand = "0.8.3"
|
|
|
|
[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
|
|
|
|
[package.metadata]
|
|
msrv = "1.56.0" |