context_server: Change command string field to PathBuf (#34873)

Release Notes:

- N/A
This commit is contained in:
Ben Brandt 2025-07-22 12:12:07 +02:00 committed by GitHub
parent 87014cec71
commit 3a651c546b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
7 changed files with 22 additions and 23 deletions

View file

@ -75,7 +75,7 @@ impl From<Range> for std::ops::Range<usize> {
impl From<Command> for extension::Command {
fn from(value: Command) -> Self {
Self {
command: value.command,
command: value.command.into(),
args: value.args,
env: value.env,
}
@ -958,7 +958,7 @@ impl ExtensionImports for WasmState {
command,
} => Ok(serde_json::to_string(&settings::ContextServerSettings {
command: Some(settings::CommandSettings {
path: Some(command.path),
path: command.path.to_str().map(|path| path.to_string()),
arguments: Some(command.args),
env: command.env.map(|env| env.into_iter().collect()),
}),