Skip to content

Commit

Permalink
chore: enhance lsp version info (#1540)
Browse files Browse the repository at this point in the history
Signed-off-by: he1pa <[email protected]>
  • Loading branch information
He1pa authored Aug 5, 2024
1 parent 5453b87 commit ba62288
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion kclvm/tools/src/LSP/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ dashmap = "5.1.0"
log = "0.4.14"
im-rc = "15.0.0"
rustc_lexer = "0.1.0"
clap = "4.3.0"
clap ={ version = "4.3.0", features = ["string"] }
maplit = "1.0.2"

kclvm-tools = { path = "../../../tools" }
Expand Down
4 changes: 2 additions & 2 deletions kclvm/tools/src/LSP/src/main_loop.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
use crate::state::LanguageServerState;
use clap::Command;
use clap::{builder::Str, Command};
use lsp_server::Connection;
use lsp_types::InitializeParams;

Expand All @@ -16,7 +16,7 @@ pub(crate) fn main_loop(
/// Get the kcl language server CLI application.
pub(crate) fn app() -> Command {
Command::new("kcl-language-server")
.version(kclvm_version::VERSION)
.version(Str::from(kclvm_version::get_version_info()))
.about("KCL language server CLI.")
.subcommand(Command::new("version").about("Show the KCL language server version"))
}

0 comments on commit ba62288

Please sign in to comment.