Skip to content

Commit

Permalink
vimrc: sg.nvim is buggy, disable it
Browse files Browse the repository at this point in the history
  • Loading branch information
jiangyinzuo committed Apr 21, 2024
1 parent 7ceab96 commit 66fc291
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 9 deletions.
10 changes: 10 additions & 0 deletions root/.config/nvim/lua/lsp/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -171,6 +171,16 @@ local function setup_lsp(on_attach, capabilities)
-- DAP configuration
dap = {},
}

-- sg is buggy
-- require("sg").setup({
-- -- Pass your own custom attach function
-- -- If you do not pass your own attach function, then the following maps are provide:
-- -- - gd -> goto definition
-- -- - gr -> goto references
-- on_attach = on_attach,
-- capabilities = capabilities,
-- })
end

function M.lspconfig()
Expand Down
9 changes: 0 additions & 9 deletions root/.config/nvim/lua/plugins/ai.lua
Original file line number Diff line number Diff line change
Expand Up @@ -48,14 +48,5 @@ elseif vim.g.ai_complete == "fittencode" then
}
elseif vim.g.ai_complete == "tabnine" then
ai_complete = { "codota/tabnine-nvim", build = "./dl_binaries.sh" }
elseif vim.g.ai_complete == "sourcegraph" then
ai_complete = {
"sourcegraph/sg.nvim",
dependencies = {
"nvim-lua/plenary.nvim", --[[ "nvim-telescope/telescope.nvim ]]
},
-- If you have a recent version of lazy.nvim, you don't need to add this!
build = "nvim -l build/init.lua",
}
end
return ai_complete
13 changes: 13 additions & 0 deletions root/.config/nvim/lua/plugins/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -137,4 +137,17 @@ return {
},
-- A graphical display window manager in neovim
-- {'altermo/nxwm',branch='x11'},
{
"sourcegraph/sg.nvim",
dependencies = {
"nvim-lua/plenary.nvim", --[[ "nvim-telescope/telescope.nvim ]]
},
config = function()
vim.keymap.set("n", "<leader>sg", function()
require("sg.extensions.telescope").fuzzy_search_results()
end)
end,
-- If you have a recent version of lazy.nvim, you don't need to add this!
build = "nvim -l build/init.lua",
},
}

0 comments on commit 66fc291

Please sign in to comment.