mirror of
https://github.com/LunarVim/LunarVim.git
synced 2025-07-14 11:24:43 +02:00
Adding tabnine for compe (#640)
This commit is contained in:
parent
881d57c6ed
commit
816c6cfa7d
3 changed files with 17 additions and 2 deletions
|
@ -68,7 +68,8 @@ O = {
|
|||
diffview = {active = false},
|
||||
bracey = {active = false},
|
||||
telescope_project = {active = false},
|
||||
dap_install = {active = false}
|
||||
dap_install = {active = false},
|
||||
tabnine = {active = false}
|
||||
|
||||
},
|
||||
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
local M = {}
|
||||
|
||||
M.config = function()
|
||||
require'compe'.setup {
|
||||
opt = {
|
||||
enabled = O.auto_complete,
|
||||
autocomplete = true,
|
||||
debug = false,
|
||||
|
@ -38,6 +38,12 @@ require'compe'.setup {
|
|||
}
|
||||
}
|
||||
|
||||
if O.plugin.tabnine.active then
|
||||
opt.source.tabnine = {kind = " ", priority=200, max_reslts=6}
|
||||
end
|
||||
|
||||
require'compe'.setup(opt)
|
||||
|
||||
local t = function(str)
|
||||
return vim.api.nvim_replace_termcodes(str, true, true, true)
|
||||
end
|
||||
|
|
|
@ -425,4 +425,12 @@ return require("packer").startup(function(use)
|
|||
|
||||
-- Elixir
|
||||
use {"elixir-editors/vim-elixir", ft = {"elixir", "eelixir", "euphoria3"}}
|
||||
|
||||
-- Tabnine
|
||||
use {
|
||||
"tzachar/compe-tabnine",
|
||||
run="./install.sh",
|
||||
requires = "hrsh7th/nvim-compe",
|
||||
disable = not O.plugin.tabnine.active
|
||||
}
|
||||
end)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue