Skip to content

Commit b58f46a

Browse files
committed
docs: improve documentation for contexts and complete binding
Signed-off-by: Tomas Slusny <slusnucky@gmail.com>
1 parent 4d2a2c6 commit b58f46a

2 files changed

Lines changed: 6 additions & 13 deletions

File tree

README.md

Lines changed: 6 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -296,28 +296,24 @@ Also see [here](/lua/CopilotChat/config.lua):
296296
-- default contexts
297297
contexts = {
298298
buffer = {
299+
description = 'Includes only the current buffer in chat context. Supports input.',
299300
-- see config.lua for implementation
300-
input = function(callback) end,
301-
resolve = function(input, source) end,
302301
},
303302
buffers = {
303+
description = 'Includes all open buffers in chat context.',
304304
-- see config.lua for implementation
305-
resolve = function(input, source) end,
306305
},
307306
file = {
307+
description = 'Includes content of provided file in chat context. Supports input.',
308308
-- see config.lua for implementation
309-
input = function(callback) end,
310-
resolve = function(input, source) end,
311309
},
312310
files = {
311+
description = 'Includes all non-hidden filenames in the current workspace in chat context. Supports input.',
313312
-- see config.lua for implementation
314-
input = function(callback) end,
315-
resolve = function(input, source) end,
316313
},
317314
git = {
315+
description = 'Includes current git diff in chat context. Supports input.',
318316
-- see config.lua for implementation
319-
input = function(callback) end,
320-
resolve = function(input, source) end,
321317
},
322318
},
323319

@@ -327,9 +323,8 @@ Also see [here](/lua/CopilotChat/config.lua):
327323
prompt = '> /COPILOT_EXPLAIN\n\nWrite an explanation for the selected code and diagnostics as paragraphs of text.',
328324
},
329325
Review = {
330-
-- see config.lua for implementation
331326
prompt = '> /COPILOT_REVIEW\n\nReview the selected code.',
332-
callback = function(response, source) end,
327+
-- see config.lua for implementation
333328
},
334329
Fix = {
335330
prompt = '> /COPILOT_GENERATE\n\nThere is a problem in this code. Rewrite the code to show it with the bug fixed.',
@@ -366,7 +361,6 @@ Also see [here](/lua/CopilotChat/config.lua):
366361
-- default mappings
367362
mappings = {
368363
complete = {
369-
detail = 'Use @<Tab> or /<Tab> for options.',
370364
insert ='<Tab>',
371365
},
372366
close = {

lua/CopilotChat/config.lua

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -283,7 +283,6 @@ return {
283283
-- default mappings
284284
mappings = {
285285
complete = {
286-
detail = 'Use @<Tab> or /<Tab> for options.',
287286
insert = '<Tab>',
288287
},
289288
close = {

0 commit comments

Comments
 (0)