Skip to content

Commit

Permalink
Update README snippet
Browse files Browse the repository at this point in the history
  • Loading branch information
julianolf committed Mar 5, 2024
1 parent 675aa29 commit 942941a
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,18 +32,22 @@ You can pass custom configurations in two different ways, by passing a Lua table
```lua
local cfg = {
configurations = {
c = { -- c lang configurations
-- C lang configurations
c = {
{
name = "Launch debugger",
type = "lldb",
request = "launch",
cwd = "${workspaceFolder}",
program = function()
local out = vim.fn.system({"make", "debug"}) -- build with debug symbols
if vim.v.shell_error ~= 0 then -- check for errors
-- Build with debug symbols
local out = vim.fn.system({"make", "debug"})
-- Check for errors
if vim.v.shell_error ~= 0 then
vim.notify(out, vim.log.levels.ERROR)
return nil
return "path/to/executable" -- return path to the debuggable program
-- Return path to the debuggable program
return "path/to/executable"
end,
},
},
Expand Down

0 comments on commit 942941a

Please sign in to comment.