.\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.48.3. .TH CLANGD "1" "July 2021" "clangd 9" "User Commands" .SH NAME clangd \- manual page for clangd 9 .SH DESCRIPTION OVERVIEW: clangd is a language server that provides IDE\-like features to editors. .SS "It should be used via an editor plugin rather than invoked directly. For more information, see:" .IP https://clang.llvm.org/extra/clangd/ https://microsoft.github.io/language\-server\-protocol/ .PP clangd accepts flags on the commandline, and in the CLANGD_FLAGS environment variable. .PP USAGE: clangd [options] .PP OPTIONS: .PP Generic Options: .HP \fB\-\-help\fR \- Display available options (\fB\-\-help\-hidden\fR for more) .HP \fB\-\-help\-list\fR \- Display list of available options (\fB\-\-help\-list\-hidden\fR for more) .HP \fB\-\-version\fR \- Display the version of this program .PP clangd compilation flags options: .HP \fB\-\-compile\-commands\-dir=\fR \- Specify a path to look for compile_commands.json. If path is invalid, clangd will look in the current directory and parent paths of each source file .HP \fB\-\-query\-driver=\fR \- Comma separated list of globs for white\-listing gcc\-compatible drivers that are safe to execute. Drivers matching any of these globs will be used to extract system includes. e.g. /usr/bin/**/clang\-*,/path/to/repo/**/g++\-* .PP clangd feature options: .HP \fB\-\-all\-scopes\-completion\fR \- If set to true, code completion will include index symbols that are not defined in the scopes (e.g. namespaces) visible from the code completion point. Such completions can insert scope qualifiers .HP \fB\-\-background\-index\fR \- Index project code in the background and persist index on disk. .HP \fB\-\-clang\-tidy\fR \- Enable clang\-tidy diagnostics .HP \fB\-\-clang\-tidy\-checks=\fR \- List of clang\-tidy checks to run (this will override .clang\-tidy files). Only meaningful when \fB\-clang\-tidy\fR flag is on .HP \fB\-\-completion\-style=\fR \- Granularity of code completion suggestions .TP =detailed \- One completion item for each semantically distinct completion, with full type information .TP =bundled \- Similar completion items (e.g. function overloads) are combined. Type information shown where possible .HP \fB\-\-fallback\-style=\fR \- clang\-format style to apply by default when no .clang\-format file is found .HP \fB\-\-header\-insertion=\fR \- Add #include directives when accepting code completions .TP =iwyu \- Include what you use. Insert the owning header for top\-level symbols, unless the header is already directly included or the symbol is forward\-declared .TP =never \- Never insert #include directives as part of code completion .HP \fB\-\-header\-insertion\-decorators\fR \- Prepend a circular dot or space before the completion label, depending on whether an include line will be inserted or not .HP \fB\-\-limit\-results=\fR \- Limit the number of results returned by clangd. 0 means no limit (default=100) .HP \fB\-\-suggest\-missing\-includes\fR \- Attempts to fix diagnostic errors caused by missing includes using index .PP clangd miscellaneous options: .HP \fB\-j=\fR \- Number of async workers used by clangd. Background index also uses this many workers. .HP \fB\-\-pch\-storage=\fR \- Storing PCHs in memory increases memory usages, but may improve performance .TP =disk \- store PCHs on disk .TP =memory \- store PCHs in memory .PP clangd protocol and logging options: .HP \fB\-\-log=\fR \- Verbosity of log messages written to stderr .TP =error \- Error messages only .TP =info \- High level execution tracing .TP =verbose \- Low level details .HP \fB\-\-offset\-encoding=\fR \- Force the offsetEncoding used for character positions. This bypasses negotiation via client capabilities .TP =utf\-8 \- Offsets are in UTF\-8 bytes .TP =utf\-16 \- Offsets are in UTF\-16 code units .HP \fB\-\-pretty\fR \- Pretty\-print JSON output