Message ID | 20230902145310.107054-8-jmcosta944@gmail.com |
---|---|
State | Changes Requested |
Delegated to: | Heinrich Schuchardt |
Headers | show |
Series | Port gen_compile_commands.py from Linux to U-Boot | expand |
On 9/2/23 16:53, Joao Marcos Costa wrote: > Add 'Integration with IDEs' section. > > For now, this section is mostly a reference to the documentation of > gen_compile_commands, also in doc/build, but it can be futurely used as > a guide for other IDE-friendly features. > > Signed-off-by: Joao Marcos Costa <jmcosta944@gmail.com> > --- > doc/build/gen_compile_commands.rst | 1 + > doc/build/tools.rst | 13 +++++++++++++ > 2 files changed, 14 insertions(+) > > diff --git a/doc/build/gen_compile_commands.rst b/doc/build/gen_compile_commands.rst > index 6b32eb678a..da812525fe 100644 > --- a/doc/build/gen_compile_commands.rst > +++ b/doc/build/gen_compile_commands.rst > @@ -1,4 +1,5 @@ > .. SPDX-License-Identifier: GPL-2.0-only > +.. _gen-compile-commands-label: You don't need a label to refer to a document. Just use a :doc: link. > > ==================== > gen_compile_commands > diff --git a/doc/build/tools.rst b/doc/build/tools.rst > index ec01722925..5cdbf27d83 100644 > --- a/doc/build/tools.rst > +++ b/doc/build/tools.rst > @@ -45,3 +45,16 @@ Launch the MSYS2 shell of the MSYS2 environment, and do the following:: > > $ make tools-only_defconfig > $ make tools-only > + > +Integration with IDEs > +--------------------- This chapter is not related to our host tools and it is not related to building. You could put it into a separate document in doc/develop/. Best regards Heinrich > + > +IDEs and text editors (e.g., VSCode, Emacs, Vim, Neovim) typically offer > +plugins to enhance the development experience, such as Clangd LSP. These > +plugins provide features like code navigation (i.e., jumping to definitions > +and declarations), code completion, and code formatting. > + > +U-Boot provides a script (i.e., scripts/gen_compile_commands.py) that > +generates a compilation database to be utilized by Clangd LSP for code > +navigation. For detailed usage instructions, please refer to the script's > +documentation: :ref:`gen-compile-commands-label`.
diff --git a/doc/build/gen_compile_commands.rst b/doc/build/gen_compile_commands.rst index 6b32eb678a..da812525fe 100644 --- a/doc/build/gen_compile_commands.rst +++ b/doc/build/gen_compile_commands.rst @@ -1,4 +1,5 @@ .. SPDX-License-Identifier: GPL-2.0-only +.. _gen-compile-commands-label: ==================== gen_compile_commands diff --git a/doc/build/tools.rst b/doc/build/tools.rst index ec01722925..5cdbf27d83 100644 --- a/doc/build/tools.rst +++ b/doc/build/tools.rst @@ -45,3 +45,16 @@ Launch the MSYS2 shell of the MSYS2 environment, and do the following:: $ make tools-only_defconfig $ make tools-only + +Integration with IDEs +--------------------- + +IDEs and text editors (e.g., VSCode, Emacs, Vim, Neovim) typically offer +plugins to enhance the development experience, such as Clangd LSP. These +plugins provide features like code navigation (i.e., jumping to definitions +and declarations), code completion, and code formatting. + +U-Boot provides a script (i.e., scripts/gen_compile_commands.py) that +generates a compilation database to be utilized by Clangd LSP for code +navigation. For detailed usage instructions, please refer to the script's +documentation: :ref:`gen-compile-commands-label`.
Add 'Integration with IDEs' section. For now, this section is mostly a reference to the documentation of gen_compile_commands, also in doc/build, but it can be futurely used as a guide for other IDE-friendly features. Signed-off-by: Joao Marcos Costa <jmcosta944@gmail.com> --- doc/build/gen_compile_commands.rst | 1 + doc/build/tools.rst | 13 +++++++++++++ 2 files changed, 14 insertions(+)