[package]
name = "dial9-viewer"
version = "0.3.3"
edition.workspace = true
license.workspace = true
repository.workspace = true
description = "CLI trace viewer and S3 browser for dial9-tokio-telemetry"
default-run = "dial9-viewer"
exclude = ["src/bin/dev_server.rs"]

[package.metadata.binstall]
pkg-url = "{ repo }/releases/download/{ name }-v{ version }/{ name }-{ target }-v{ version }{ archive-suffix }"

[features]
dev-server = ["dep:s3s", "dep:s3s-fs", "dep:s3s-aws", "dep:tempfile"]

[[bin]]
name = "dial9-viewer"
path = "src/main.rs"

[[bin]]
name = "dev-server"
path = "src/bin/dev_server.rs"
required-features = ["dev-server"]

[dependencies]
axum = "0.8"
axum-extra = { version = "0.10", features = ["query"] }
clap = { version = "4", features = ["derive"] }
flate2 = "1"
futures = "0.3"
serde = { version = "1", features = ["derive"] }
serde_json = "1"
tokio = { version = "1", features = ["rt-multi-thread", "macros", "signal"] }
rust-embed = { version = "8", features = ["mime-guess"] }
mime_guess = "2"
tower-http = { version = "0.6", features = ["fs"] }
tracing = "0.1"
tracing-subscriber = { version = "0.3", features = ["env-filter"] }
aws-config = { version = "1", features = ["behavior-version-latest"] }
aws-sdk-s3 = { version = "1", features = ["behavior-version-latest"] }
anyhow = "1"
s3s = { version = "0.13.0", optional = true }
s3s-fs = { version = "0.13.0", optional = true }
s3s-aws = { version = "0.13.0", optional = true }
tempfile = { version = "3", optional = true }

[dev-dependencies]
assert2 = { workspace = true }
reqwest = { version = "0.12", default-features = false, features = ["json"] }
s3s = "0.13.0"
s3s-fs = "0.13.0"
s3s-aws = "0.13.0"
tempfile = "3"
urlencoding = "2"
