diff --git a/Cargo.toml b/Cargo.toml index 0bacc51..17935a9 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -3,19 +3,21 @@ name = "shvcall" version = "3.0.0" edition = "2021" +[features] +readline = ["dep:crossterm", "dep:rustyline-async"] + # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [dependencies] simple_logger = { git = "https://github.com/fvacek/rust-simple_logger.git", branch = "main", features = ["stderr"] } shvproto = { git = "https://github.com/silicon-heaven/libshvproto-rs.git", branch = "master" } shvrpc = { git = "https://github.com/silicon-heaven/libshvrpc-rs.git", branch = "master" } #shvrpc = { path = "../libshvrpc-rs" } - futures = "0.3.29" async-std = { version = "1.12.0", features = ["attributes"] } log = "0.4.20" clap = { version = "4.4.12", features = ["derive"] } -rustyline-async = { version = "0.4.1" } -crossterm = { version = "0.27.0" } +rustyline-async = { version = "0.4.1", optional = true } +crossterm = { version = "0.27.0", optional = true } url = "2.4.1" diff --git a/src/main.rs b/src/main.rs index ef57120..5a0a08d 100644 --- a/src/main.rs +++ b/src/main.rs @@ -87,9 +87,9 @@ pub(crate) fn main() -> Result { } logger.init().unwrap(); - log::info!("====================================================="); - log::info!("{} starting", std::module_path!()); - log::info!("====================================================="); + info!("====================================================="); + info!("{} starting", std::module_path!()); + info!("====================================================="); // let rpc_timeout = Duration::from_millis(DEFAULT_RPC_TIMEOUT_MSEC); let url = Url::parse(&opts.url)?;