Browse Source

Merge pull request #6888 from rcorre/compiledb

Document compiledb generation.
Max Hilbrunner 2 years ago
parent
commit
12720dd582
1 changed files with 12 additions and 0 deletions
  1. 12 0
      contributing/development/configuring_an_ide/index.rst

+ 12 - 0
contributing/development/configuring_an_ide/index.rst

@@ -24,3 +24,15 @@ Development Environment), here are setup instructions for some popular ones:
    xcode
    xcode
 
 
 It is possible to use other IDEs, but their setup is not documented yet.
 It is possible to use other IDEs, but their setup is not documented yet.
+
+If your editor supports the `language server protocol <https://microsoft.github.io/language-server-protocol/>`__,
+you can use `clangd <https://clangd.llvm.org>`__ for completion, diagnostics, and more.
+You can generate a compilation database for use with clangd one of two ways:
+
+.. code-block:: shell
+
+   # Generate compile_commands.json while compiling
+   scons compiledb=yes
+
+   # Generate compile_commands.json without compiling
+   scons compiledb=yes compile_commands.json