[package]
name         = "tui-file-explorer"
version      = "1.0.2"
edition      = "2021"
authors      = ["Sorin Irimies <sorinirimies@gmail.com>"]
license      = "MIT"
repository   = "https://github.com/sorinirimies/tui-file-explorer"
description  = "A self-contained, keyboard-driven file-browser widget for Ratatui"
categories   = ["command-line-utilities", "filesystem"]
keywords     = ["tui", "ratatui", "file-explorer", "widget", "terminal"]
readme       = "README.md"
exclude      = [
    "target/",
    ".gitignore",
    "rules.md",
    "justfile",
    "cliff.toml",
    "scripts/",
    ".gitea/",
    "examples/vhs/generated/",
]

# ── Features ──────────────────────────────────────────────────────────────────
#
# The `cli` feature (on by default) pulls in `clap` and enables the `tfe`
# binary. Library users who only want the widget can opt out:
#
#   [dependencies]
#   tui-file-explorer = { version = "0.1", default-features = false }
#
[features]
default = ["cli"]
# The `cli` feature pulls in `clap` and enables the `tfe` binary.
# Library users who only want the widget can opt out:
#
#   [dependencies]
#   tui-file-explorer = { version = "...", default-features = false }
cli = ["dep:clap"]

# ── Dependencies ──────────────────────────────────────────────────────────────

[dependencies]
ratatui    = "0.30"
crossterm  = "0.29"
clap       = { version = "4", features = ["derive", "color", "wrap_help"], optional = true }
tui-slider = "0.3.2"

[target.'cfg(unix)'.dependencies]
libc = "0.2"

[dev-dependencies]
tempfile = "3"

# ── Binaries ──────────────────────────────────────────────────────────────────

[[bin]]
name              = "tfe"
path              = "src/main.rs"
required-features = ["cli"]

# ── Examples ──────────────────────────────────────────────────────────────────

[[example]]
name = "basic"
path = "examples/basic.rs"

[[example]]
name = "theme_switcher"
path = "examples/theme_switcher.rs"

[[example]]
name = "dual_pane"
path = "examples/dual_pane.rs"

[[example]]
name = "options"
path = "examples/options.rs"

[[example]]
name = "open_file"
path = "examples/open_file.rs"

[[example]]
name = "full"
path = "examples/full.rs"