[package]
name = "editorconfiger"
version = "0.6.0"
description = "Plain tool to validate and compare .editorconfig files"
authors = ["egoroff <egoroff@gmail.com>"]
keywords = ["editorconfig"]
repository = "https://github.com/aegoroff/editorconfiger"
edition = "2024"
license = "MIT"

# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

[build-dependencies] # <-- We added this and everything after!
lalrpop = "=0.23.1"

[dependencies]
lalrpop-util  = { version = "=0.23.1", features = ["lexer", "unicode"] }
jwalk = "=0.8.1"
aho-corasick = "=1.1.4"
winnow = "=1.0.2"
num_cpus = "=1.17.0"

console = {version = "=0.16.3", optional = true }
prettytable-rs = { version = "=0.10.0", optional = true }
clap = { version = "=4.6.1", features = ["std", "color", "suggestions", "cargo"], optional = true }
clap_complete = { version = "=4.6.2", optional = true }
bugreport = { version = "=0.6.0", optional = true }

miette = { version = "=7.6.0", features = ["fancy"] }

[target.'cfg(target_os = "linux")'.dependencies]
mimalloc = "=0.1.50"

[dev-dependencies]
test-case = "=3.3.1"

[features]
build-binary = ["clap", "clap_complete", "console", "prettytable-rs", "bugreport"]

[[bin]]
name = "editorconfiger"
required-features = ["build-binary"]

[profile.release]
lto = true
strip = true
panic = 'abort'

[package.metadata.deb]
assets = [
    ["target/release/editorconfiger", "usr/bin/", "755"],
]

[package.metadata.generate-rpm]
assets = [
    { source = "target/release/editorconfiger", dest = "/usr/bin/editorconfiger", mode = "0755" },
]

[lints.rust]
unsafe_code = "forbid"
