[package]
name = "aptu-coder-core"
version = { workspace = true }
edition = { workspace = true }
rust-version = { workspace = true }
authors = { workspace = true }
license = { workspace = true }
repository = { workspace = true }
homepage = { workspace = true }
description = "Multi-language AST analysis library using tree-sitter"
readme = "README.md"
keywords = ["tree-sitter", "code-analysis", "ast", "parser", "static-analysis"]
categories = ["development-tools", "parser-implementations"]
publish = true

[lints.rust]
unexpected_cfgs = { level = "warn", check-cfg = ["cfg(coverage)", "cfg(coverage_nightly)"] }

[package.metadata.docs.rs]
all-features = true
rustdoc-args = ["--cfg", "docsrs"]

[features]
default = ["lang-rust", "lang-go", "lang-java", "lang-kotlin", "lang-python", "lang-typescript", "lang-tsx", "lang-fortran", "lang-javascript", "lang-cpp", "lang-csharp"]
schemars = ["dep:schemars"]
lang-rust = ["dep:tree-sitter-rust"]
lang-go = ["dep:tree-sitter-go"]
lang-cpp = ["dep:tree-sitter-cpp"]
lang-java = ["dep:tree-sitter-java"]
lang-kotlin = ["dep:tree-sitter-kotlin-ng"]
lang-python = ["dep:tree-sitter-python"]
lang-typescript = ["dep:tree-sitter-typescript"]
lang-javascript = ["dep:tree-sitter-javascript"]
lang-tsx = ["dep:tree-sitter-typescript"]
lang-fortran = ["dep:tree-sitter-fortran"]
lang-csharp = ["dep:tree-sitter-c-sharp"]

[dependencies]
tree-sitter = { workspace = true }
rayon = { workspace = true }
ignore = { workspace = true }
lru = { workspace = true }
serde = { workspace = true }
serde_json = { workspace = true }
base64 = { workspace = true }
thiserror = { workspace = true }
tracing = { workspace = true }
tokio-util = { workspace = true }
tempfile = { workspace = true }
tree-sitter-rust = { workspace = true, optional = true }
tree-sitter-go = { workspace = true, optional = true }
tree-sitter-cpp = { workspace = true, optional = true }
tree-sitter-c-sharp = { workspace = true, optional = true }
tree-sitter-java = { workspace = true, optional = true }
tree-sitter-kotlin-ng = { workspace = true, optional = true }
tree-sitter-python = { workspace = true, optional = true }
tree-sitter-typescript = { workspace = true, optional = true }
tree-sitter-javascript = { workspace = true, optional = true }
tree-sitter-fortran = { workspace = true, optional = true }
schemars = { workspace = true, optional = true }

[dev-dependencies]
tempfile = { workspace = true }
tokio = { workspace = true }
tracing-subscriber = { workspace = true }
schemars = { workspace = true }
serde_json = { workspace = true }
criterion = { workspace = true, features = ["html_reports"] }
tokio-util = { workspace = true }

[[bench]]
name = "analysis"
harness = false
path = "benches/analysis.rs"
