fix(my-account-ui): [CUSTMIC-] delete backupt add copilot
This commit is contained in:
parent
7f0f862b1f
commit
230929c4a5
1
backup
1
backup
|
|
@ -1 +0,0 @@
|
||||||
Subproject commit 7d954aef6198f4b244517c259dbcdc6a746df7e1
|
|
||||||
|
|
@ -9,93 +9,68 @@ return {
|
||||||
'L3MON4D3/LuaSnip',
|
'L3MON4D3/LuaSnip',
|
||||||
version = '2.*',
|
version = '2.*',
|
||||||
build = (function()
|
build = (function()
|
||||||
-- Build Step is needed for regex support in snippets.
|
|
||||||
-- This step is not supported in many windows environments.
|
|
||||||
-- Remove the below condition to re-enable on windows.
|
|
||||||
if vim.fn.has 'win32' == 1 or vim.fn.executable 'make' == 0 then
|
if vim.fn.has 'win32' == 1 or vim.fn.executable 'make' == 0 then
|
||||||
return
|
return
|
||||||
end
|
end
|
||||||
return 'make install_jsregexp'
|
return 'make install_jsregexp'
|
||||||
end)(),
|
end)(),
|
||||||
dependencies = {
|
dependencies = {},
|
||||||
-- `friendly-snippets` contains a variety of premade snippets.
|
|
||||||
-- See the README about individual language/framework/plugin snippets:
|
|
||||||
-- https://github.com/rafamadriz/friendly-snippets
|
|
||||||
-- {
|
|
||||||
-- 'rafamadriz/friendly-snippets',
|
|
||||||
-- config = function()
|
|
||||||
-- require('luasnip.loaders.from_vscode').lazy_load()
|
|
||||||
-- end,
|
|
||||||
-- },
|
|
||||||
},
|
|
||||||
opts = {},
|
opts = {},
|
||||||
},
|
},
|
||||||
'folke/lazydev.nvim',
|
'folke/lazydev.nvim',
|
||||||
|
|
||||||
|
-- Copilot backend (Lua) -- disable inline/panel; we'll use Blink only
|
||||||
|
{
|
||||||
|
'zbirenbaum/copilot.lua',
|
||||||
|
cmd = 'Copilot',
|
||||||
|
build = ':Copilot auth',
|
||||||
|
event = 'BufReadPost',
|
||||||
|
opts = {
|
||||||
|
suggestion = { enabled = false },
|
||||||
|
panel = { enabled = false },
|
||||||
},
|
},
|
||||||
|
},
|
||||||
|
|
||||||
|
-- Blink source for Copilot
|
||||||
|
'giuxtaposition/blink-cmp-copilot',
|
||||||
|
},
|
||||||
|
|
||||||
--- @module 'blink.cmp'
|
--- @module 'blink.cmp'
|
||||||
--- @type blink.cmp.Config
|
--- @type blink.cmp.Config
|
||||||
opts = {
|
opts = {
|
||||||
keymap = {
|
keymap = { preset = 'default' },
|
||||||
-- 'default' (recommended) for mappings similar to built-in completions
|
appearance = { nerd_font_variant = 'mono' },
|
||||||
-- <c-y> to accept ([y]es) the completion.
|
completion = { documentation = { auto_show = false, auto_show_delay_ms = 500 } },
|
||||||
-- This will auto-import if your LSP supports it.
|
|
||||||
-- This will expand snippets if the LSP sent a snippet.
|
|
||||||
-- 'super-tab' for tab to accept
|
|
||||||
-- 'enter' for enter to accept
|
|
||||||
-- 'none' for no mappings
|
|
||||||
--
|
|
||||||
-- For an understanding of why the 'default' preset is recommended,
|
|
||||||
-- you will need to read `:help ins-completion`
|
|
||||||
--
|
|
||||||
-- No, but seriously. Please read `:help ins-completion`, it is really good!
|
|
||||||
--
|
|
||||||
-- All presets have the following mappings:
|
|
||||||
-- <tab>/<s-tab>: move to right/left of your snippet expansion
|
|
||||||
-- <c-space>: Open menu or open docs if already open
|
|
||||||
-- <c-n>/<c-p> or <up>/<down>: Select next/previous item
|
|
||||||
-- <c-e>: Hide menu
|
|
||||||
-- <c-k>: Toggle signature help
|
|
||||||
--
|
|
||||||
-- See :h blink-cmp-config-keymap for defining your own keymap
|
|
||||||
preset = 'default',
|
|
||||||
|
|
||||||
-- For more advanced Luasnip keymaps (e.g. selecting choice nodes, expansion) see:
|
|
||||||
-- https://github.com/L3MON4D3/LuaSnip?tab=readme-ov-file#keymaps
|
|
||||||
},
|
|
||||||
|
|
||||||
appearance = {
|
|
||||||
-- 'mono' (default) for 'Nerd Font Mono' or 'normal' for 'Nerd Font'
|
|
||||||
-- Adjusts spacing to ensure icons are aligned
|
|
||||||
nerd_font_variant = 'mono',
|
|
||||||
},
|
|
||||||
|
|
||||||
completion = {
|
|
||||||
-- By default, you may press `<c-space>` to show the documentation.
|
|
||||||
-- Optionally, set `auto_show = true` to show the documentation after a delay.
|
|
||||||
documentation = { auto_show = false, auto_show_delay_ms = 500 },
|
|
||||||
},
|
|
||||||
|
|
||||||
sources = {
|
sources = {
|
||||||
default = { 'lsp', 'path', 'snippets', 'lazydev' },
|
-- add "copilot" to the default sources
|
||||||
|
default = { 'lsp', 'path', 'snippets', 'lazydev', 'copilot' },
|
||||||
providers = {
|
providers = {
|
||||||
lazydev = { module = 'lazydev.integrations.blink', score_offset = 100 },
|
lazydev = { module = 'lazydev.integrations.blink', score_offset = 100 },
|
||||||
|
|
||||||
|
-- define the Copilot provider for Blink
|
||||||
|
copilot = {
|
||||||
|
name = 'copilot',
|
||||||
|
module = 'blink-cmp-copilot',
|
||||||
|
async = true,
|
||||||
|
score_offset = 100, -- slightly boost Copilot
|
||||||
|
-- optional: mark items visually as "Copilot"
|
||||||
|
transform_items = function(_, items)
|
||||||
|
local Kind = require('blink.cmp.types').CompletionItemKind
|
||||||
|
local idx = #Kind + 1
|
||||||
|
Kind[idx] = 'Copilot'
|
||||||
|
for _, item in ipairs(items) do
|
||||||
|
item.kind = idx
|
||||||
|
end
|
||||||
|
return items
|
||||||
|
end,
|
||||||
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
snippets = { preset = 'luasnip' },
|
snippets = { preset = 'luasnip' },
|
||||||
|
|
||||||
-- Blink.cmp includes an optional, recommended rust fuzzy matcher,
|
|
||||||
-- which automatically downloads a prebuilt binary when enabled.
|
|
||||||
--
|
|
||||||
-- By default, we use the Lua implementation instead, but you may enable
|
|
||||||
-- the rust implementation via `'prefer_rust_with_warning'`
|
|
||||||
--
|
|
||||||
-- See :h blink-cmp-config-fuzzy for more information
|
|
||||||
fuzzy = { implementation = 'lua' },
|
fuzzy = { implementation = 'lua' },
|
||||||
|
|
||||||
-- Shows a signature help window while you type arguments for a function
|
|
||||||
signature = { enabled = true },
|
signature = { enabled = true },
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
-- vim: ts=2 sts=2 sw=2 et
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue