[package]
name = "rok-cli"
version.workspace = true
edition.workspace = true
license.workspace = true
authors.workspace = true
description = "Developer CLI for rok-based Axum applications"
keywords = ["cli", "axum", "scaffold", "rok", "codegen"]
categories = ["command-line-utilities", "development-tools"]
repository.workspace = true
homepage.workspace = true

[[bin]]
name = "rok"
path = "src/main.rs"

[features]
default = ["tui", "repl"]
full = ["tui", "tui-studio", "repl"]
## Terminal UI dashboard (DB browser, migrations, features, queue, perf).
tui = ["dep:ratatui", "dep:crossterm", "dep:tracing", "dep:tracing-subscriber"]
## Studio tab within the TUI (requires rok-testing).
tui-studio = ["tui", "dep:rok-testing", "rok-testing/studio"]
## Interactive tinker REPL.
repl = ["dep:rustyline"]

[dependencies]
clap = { workspace = true }
clap_complete = { version = "4", features = ["unstable-dynamic"] }
tokio = { workspace = true }
sqlx = { workspace = true, features = ["postgres"] }
dotenvy = { workspace = true }
rand = { workspace = true }
anyhow = { workspace = true }
heck = { workspace = true }
serde_json = { workspace = true }
chrono = { workspace = true }
dialoguer = "0.11"
console = "0.15"
rok-orm = { path = "../rok-orm", version = "0.6", features = ["migrate", "postgres"] }
glob = "0.3"
serde = { workspace = true }
serde_yaml = "0.9"
semver = "1"
ureq = { version = "3", features = ["json"] }
toml = "0.8"
dirs-next = "2"
jsonwebtoken = { workspace = true }
base64 = { workspace = true }
rok-auth = { path = "../rok-auth", version = "0.6" }

# ── TUI dependencies (gated by `tui` feature) ──────────────────────────────────
ratatui   = { version = "0.28", optional = true }
crossterm = { version = "0.28", optional = true }
rok-testing = { path = "../rok-testing", version = "0.6", optional = true }
tracing   = { workspace = true, optional = true }
tracing-subscriber = { workspace = true, optional = true }

# ── REPL dependencies (gated by `repl` feature) ────────────────────────────────
rustyline = { version = "14", optional = true }
