typescript: Improve installation checks for vtsls
(#20197)
This PR improves the installation checks for `vtsls`. Previously we were checking the installed version of TypeScript against the latest available version to determine whether we needed to installed the `vtsls` language server or not. However, these are two independent concerns, so we should be checking individually whether `typescript` or `@vtsls/language-server` need to be installed/updated. Closes https://github.com/zed-industries/zed/issues/18349. Release Notes: - typescript: Fixed an issue where `@vtsls/language-server` may not have been updated to the latest version.
This commit is contained in:
parent
bc4bd2e168
commit
16e9b4ceeb
2 changed files with 39 additions and 20 deletions
|
@ -161,6 +161,10 @@ impl NodeRuntime {
|
|||
directory: &Path,
|
||||
packages: &[(&str, &str)],
|
||||
) -> Result<()> {
|
||||
if packages.is_empty() {
|
||||
return Ok(());
|
||||
}
|
||||
|
||||
let packages: Vec<_> = packages
|
||||
.iter()
|
||||
.map(|(name, version)| format!("{name}@{version}"))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue