Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
tailwind: Allow configuring custom tailwind server build (#11921)
Thorsten Ball90b631ff3e54
diff --git a/crates/languages/src/tailwind.rs b/crates/languages/src/tailwind.rsindex 41572257b90..f872b5a56a2 100644--- a/crates/languages/src/tailwind.rs+++ b/crates/languages/src/tailwind.rs@@ -42,6 +42,40 @@ impl LspAdapter for TailwindLspAdapter {LanguageServerName(Self::SERVER_NAME.into())}+ async fn check_if_user_installed(+ &self,+ _delegate: &dyn LspAdapterDelegate,+ cx: &AsyncAppContext,+ ) -> Option<LanguageServerBinary> {+ let configured_binary = cx+ .update(|cx| {+ ProjectSettings::get_global(cx)+ .lsp+ .get(Self::SERVER_NAME)+ .and_then(|s| s.binary.clone())+ })+ .ok()??;++ let path = if let Some(configured_path) = configured_binary.path.map(PathBuf::from) {+ configured_path+ } else {+ self.node.binary_path().await.ok()?+ };++ let arguments = configured_binary+ .arguments+ .unwrap_or_default()+ .iter()+ .map(|arg| arg.into())+ .collect();++ Some(LanguageServerBinary {+ path,+ arguments,+ env: None,+ })+ }+async fn fetch_latest_server_version(&self,_: &dyn LspAdapterDelegate,