Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 7 additions & 8 deletions lib/bundlex/lsp/config.ex
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
defmodule Bundlex.LSP.Config do
@moduledoc false

# Generates LSP configuration files (compile_commands.json, compile_flags.txt)
# for C/C++ code analysis tools like clangd.

Expand All @@ -12,14 +13,12 @@ defmodule Bundlex.LSP.Config do
optional(:output) => String.t()
}

@doc """
Generates LSP configuration files from a list of build commands.

## Returns

`{:ok, [{:compile_commands_json, path} | {:compile_flags_txt, path}]}`
or `{:error, reason}` if all writes fail.
"""
# Generates LSP configuration files from a list of build commands.
#
# ## Returns
#
# `{:ok, [{:compile_commands_json, path} | {:compile_flags_txt, path}]}`
# or `{:error, reason}` if all writes fail.
@spec generate(commands :: [String.t()], project_dir :: String.t()) ::
{:ok, [{atom, String.t()}]} | {:error, String.t()}
Comment thread
khamilowicz marked this conversation as resolved.
Outdated
def generate(commands, project_dir) do
Expand Down
Loading