Skip to content

Commit 829be3a

Browse files
committed
fix(context): add actual line content in cursor_data
1 parent 53d1fad commit 829be3a

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

lua/opencode/context.lua

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -347,7 +347,12 @@ end
347347
local function format_cursor_data_part(cursor_data)
348348
return {
349349
type = 'text',
350-
text = vim.json.encode({ context_type = 'cursor-data', line = cursor_data.line, column = cursor_data.column }),
350+
text = vim.json.encode({
351+
context_type = 'cursor-data',
352+
line = cursor_data.line,
353+
column = cursor_data.column,
354+
line_content = cursor_data.line_content,
355+
}),
351356
synthetic = true,
352357
}
353358
end

0 commit comments

Comments
 (0)