Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: enhance lsp version info #1540

Merged
merged 1 commit into from
Aug 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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"))
}
Loading