aboutsummaryrefslogtreecommitdiff
path: root/lua/user
diff options
context:
space:
mode:
Diffstat (limited to 'lua/user')
-rw-r--r--lua/user/cmp.lua2
-rw-r--r--lua/user/gitsigns.lua7
-rw-r--r--lua/user/keymaps.lua4
-rw-r--r--lua/user/lsp/handlers.lua2
-rw-r--r--lua/user/plugins.lua3
5 files changed, 16 insertions, 2 deletions
diff --git a/lua/user/cmp.lua b/lua/user/cmp.lua
index b52f421..51eecfc 100644
--- a/lua/user/cmp.lua
+++ b/lua/user/cmp.lua
@@ -10,7 +10,7 @@ end
require("luasnip/loaders/from_vscode").lazy_load()
-local check_backspace = function()
+local check_backspace = function()
local col = vim.fn.col "." - 1
return col == 0 or vim.fn.getline("."):sub(col, col):match "%s"
end
diff --git a/lua/user/gitsigns.lua b/lua/user/gitsigns.lua
new file mode 100644
index 0000000..2780a58
--- /dev/null
+++ b/lua/user/gitsigns.lua
@@ -0,0 +1,7 @@
+local status_ok, gitsigns = pcall(require, "gitsigns")
+if not status_ok then
+ print "nvim-lsp-installer not opened correctly"
+ return
+end
+
+gitsigns.setup({})
diff --git a/lua/user/keymaps.lua b/lua/user/keymaps.lua
index c0291c9..e6fa25c 100644
--- a/lua/user/keymaps.lua
+++ b/lua/user/keymaps.lua
@@ -63,3 +63,7 @@ keymap("n", "<leader>so", "<cmd>SessionManager load_session<CR>", opts)
-- Bbye
keymap("n", "<leader>q", "<cmd>Bdelete<CR>", opts)
+
+-- Random
+keymap("n", "<leader>b", ":colorscheme gruvbox<CR>:set background=light<CR>", opts)
+keymap("n", "<leader>n", ":colorscheme darkplus<CR>:set background=daret background=light<CR>", opts)
diff --git a/lua/user/lsp/handlers.lua b/lua/user/lsp/handlers.lua
index 9b35d98..a5f78d7 100644
--- a/lua/user/lsp/handlers.lua
+++ b/lua/user/lsp/handlers.lua
@@ -83,6 +83,6 @@ if not status_ok then
return
end
-M.capabilities = cmp_nvim_lsp.update_capabilities(capabilities)
+M.capabilities = cmp_nvim_lsp.default_capabilities(capabilities)
return M
diff --git a/lua/user/plugins.lua b/lua/user/plugins.lua
index c1c8e8c..2e363ec 100644
--- a/lua/user/plugins.lua
+++ b/lua/user/plugins.lua
@@ -88,6 +88,9 @@ return packer.startup(function(use)
use "goolord/alpha-nvim"
use "Shatur/neovim-session-manager"
+
+ use "lewis6991/gitsigns.nvim"
+
if PACKER_BOOTSTRAP then
require("packer").sync()
end