1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
|
return {
{
"saghen/blink.compat",
opts = {},
},
{
"saghen/blink.cmp",
dependencies = {
"rafamadriz/friendly-snippets",
"fang2hou/blink-copilot",
"rcarriga/cmp-dap",
"xzbdmw/colorful-menu.nvim",
},
opts = {
keymap = {
preset = "cmdline",
["<CR>"] = { "accept", "fallback" },
},
appearance = {
use_nvim_cmp_as_default = true,
},
completion = {
menu = {
draw = {
-- treesitter = { "lsp" },
-- We don't need label_description now because label and label_description are already
-- combined together in label by colorful-menu.nvim.
columns = { { "kind_icon" }, { "label", gap = 1 } },
components = {
label = {
text = function(ctx)
return require("colorful-menu").blink_components_text(ctx)
end,
highlight = function(ctx)
return require("colorful-menu").blink_components_highlight(
ctx
)
end,
},
},
},
},
list = {
selection = {
preselect = function()
return not require("blink.cmp").snippet_active({ direction = 1 })
end,
},
},
documentation = { auto_show = true },
},
signature = {
enabled = true,
trigger = {
enabled = true,
show_on_keyword = true,
show_on_insert = true,
},
},
sources = {
default = { "lazydev", "lsp", "copilot", "snippets", "path", "buffer" },
per_filetype = {
["dap-repl"] = { "dap" },
},
providers = {
path = {
opts = {
get_cwd = vim.fn.getcwd,
},
},
copilot = {
name = "copilot",
module = "blink-copilot",
score_offset = 100,
async = true,
},
lazydev = {
name = "LazyDev",
module = "lazydev.integrations.blink",
-- make lazydev completions top priority (see `:h blink.cmp`)
score_offset = 100,
},
dap = { name = "dap", module = "blink.compat.source" },
},
},
},
},
{
"saghen/blink.pairs",
version = "*",
dependencies = "saghen/blink.download",
opts = {
mappings = {
disabled_filetypes = {},
},
highlights = {
groups = {
"BlinkIndentOrange",
"BlinkIndentViolet",
"BlinkIndentBlue",
"BlinkIndentRed",
"BlinkIndentCyan",
"BlinkIndentYellow",
"BlinkIndentGreen",
},
},
},
},
}
|