[package]
name = "pop-cli"
description = "An all-in-one tool for Polkadot development."
version.workspace = true
edition.workspace = true
documentation.workspace = true
license.workspace = true
readme = "README.md"
repository.workspace = true
rust-version.workspace = true

[lints.clippy]
type_complexity = "allow"
too_many_arguments = "allow"

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

[package.metadata.binstall]
pkg-url = "{ repo }/releases/download/v{ version }/pop-{ target }.tar.gz"
pkg-fmt = "tgz"

[dependencies]
anyhow.workspace = true
clap.workspace = true
clap_complete.workspace = true
cliclack.workspace = true
console.workspace = true
dirs.workspace = true
duct.workspace = true
env_logger.workspace = true
log.workspace = true
os_info.workspace = true
psvm.workspace = true
reqwest.workspace = true
rustilities = { workspace = true, features = ["manifest"]}
serde = { workspace = true, features = ["derive"] }
serde_json.workspace = true
strum.workspace = true
strum_macros.workspace = true
tempfile.workspace = true
time.workspace = true
tokio.workspace = true
toml.workspace = true
url.workspace = true

# contracts
pop-contracts = { path = "../pop-contracts", version = "0.13.0", default-features = false, optional = true }
sp-core = { workspace = true }

# parachains
pop-chains = { path = "../pop-chains", version = "0.13.0", optional = true }
git2 = { workspace = true, optional = true }
regex.workspace = true
tracing-subscriber = { workspace = true, optional = true }
scale-value = { workspace = true, optional = true }
scale-info = { workspace = true }

# telemetry
pop-telemetry = { path = "../pop-telemetry", version = "0.13.0", optional = true }

# common
pop-common = { path = "../pop-common", version = "0.13.0" }

# fork
pop-fork = { path = "../pop-fork", version = "0.13.0", optional = true }

# wallet-integration
axum = { workspace = true, optional = true }
open = { workspace = true, optional = true }
tower-http = { workspace = true, features = ["fs", "cors"], optional = true }

[dev-dependencies]
mockito.workspace = true
subxt-signer = { workspace = true}
subxt = { workspace = true }
jsonrpsee = { version = "0.24", features = ["ws-client"] }
hex.workspace = true
scale.workspace = true

[features]
default = ["chain", "telemetry", "contract"]
chain = ["dep:pop-chains", "dep:pop-fork", "dep:git2", "dep:tracing-subscriber", "dep:scale-value", "wallet-integration"]
contract = ["dep:pop-contracts", "wallet-integration"]
telemetry = ["dep:pop-telemetry"]
wallet-integration = ["dep:axum", "dep:open", "dep:tower-http"]
integration-tests = ["pop-common/integration-tests"]
