languages: Recognize .clangd as YAML (#43557)

Follow-up to: https://github.com/zed-industries/zed/pull/43469

Thanks @WeetHet for [the idea]([WeetHet](https://github.com/WeetHet)).

Release Notes:

- Added support for identifying. .clangd files as YAML by default
This commit is contained in:
Peter Tripp authored and GitHub committed 2025-11-26 15:55:23 +01:00
1 parent 794c51d8eb
commit f92161d390
3 files changed
+5 -2

No files matched your search

+3 -1
View File
@@ -78,6 +78,7 @@ You can pass any number of arguments to clangd. To see a full set of available o
By default Zed will use the `clangd` language server for formatting C++ code. The Clangd is the same as the `clang-format` CLI tool. To configure this you can add a `.clang-format` file. For example:
```yaml
# yaml-language-server: $schema=https://json.schemastore.org/clang-format-21.x.json
---
BasedOnStyle: LLVM
IndentWidth: 4
@@ -106,7 +107,8 @@ You can trigger formatting via {#kb editor::Format} or the `editor: format` acti
In the root of your project, it is generally common to create a `.clangd` file to set extra configuration.
```text
```yaml
# yaml-language-server: $schema=https://json.schemastore.org/clangd.json
CompileFlags:
Add:
- "--include-directory=/path/to/include"