Compare commits
6 Commits
ba05846b9f
...
master
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
d9ca38317d | ||
|
|
88ce959c86 | ||
|
|
c3bc46ffe1 | ||
|
|
1b92d75ae7 | ||
|
|
fd6e0bdf7c | ||
|
|
b0e5ba4d12 |
@@ -24,9 +24,6 @@ return {
|
||||
variableTypes = {
|
||||
enabled = true,
|
||||
},
|
||||
functionLikeReturnTypes = {
|
||||
enabled = true,
|
||||
},
|
||||
},
|
||||
},
|
||||
---@type lspconfig.settings.vtsls
|
||||
|
||||
47
after/plugin/comment.lua
Normal file
47
after/plugin/comment.lua
Normal file
@@ -0,0 +1,47 @@
|
||||
local comment = require("Comment")
|
||||
|
||||
local options = {
|
||||
---Add a space b/w comment and the line
|
||||
padding = true,
|
||||
---Whether the cursor should stay at its position
|
||||
sticky = true,
|
||||
---Lines to be ignored while (un)comment
|
||||
ignore = nil,
|
||||
---LHS of toggle mappings in NORMAL mode
|
||||
toggler = {
|
||||
---Line-comment toggle keymap
|
||||
line = "<leader>cc",
|
||||
---Block-comment toggle keymap
|
||||
block = "<leader>cb",
|
||||
},
|
||||
---LHS of operator-pending mappings in NORMAL and VISUAL mode
|
||||
opleader = {
|
||||
---Line-comment keymap
|
||||
line = "cc",
|
||||
---Block-comment keymap
|
||||
block = "cb",
|
||||
},
|
||||
---LHS of extra mappings
|
||||
extra = {
|
||||
---Add comment on the line above
|
||||
above = "gcO",
|
||||
---Add comment on the line below
|
||||
below = "gco",
|
||||
---Add comment at the end of line
|
||||
eol = "gcA",
|
||||
},
|
||||
---Enable keybindings
|
||||
---NOTE: If given `false` then the plugin won't create any mappings
|
||||
mappings = {
|
||||
---Operator-pending mapping; `gcc` `gbc` `gc[count]{motion}` `gb[count]{motion}`
|
||||
basic = true,
|
||||
---Extra mapping; `gco`, `gcO`, `gcA`
|
||||
extra = false,
|
||||
},
|
||||
---Function to call before (un)comment
|
||||
pre_hook = nil,
|
||||
---Function to call after (un)comment
|
||||
post_hook = nil,
|
||||
}
|
||||
|
||||
comment.setup(options)
|
||||
@@ -1,3 +1,4 @@
|
||||
local utils = require("utils")
|
||||
local gitsigns = require("gitsigns")
|
||||
|
||||
gitsigns.setup({
|
||||
@@ -7,3 +8,16 @@ gitsigns.setup({
|
||||
},
|
||||
})
|
||||
require("scrollbar.handlers.gitsigns").setup()
|
||||
|
||||
local function prev_hunk()
|
||||
gitsigns.nav_hunk("prev")
|
||||
end
|
||||
|
||||
local function next_hunk()
|
||||
gitsigns.nav_hunk("next")
|
||||
end
|
||||
|
||||
utils.nmap("<leader>vb", gitsigns.blame_line, "Toggle current line blame")
|
||||
utils.nmap("<leader>vh", gitsigns.preview_hunk, "Preview hunk")
|
||||
utils.nmap("<leader>v[", prev_hunk, "Previous hunk")
|
||||
utils.nmap("<leader>v]", next_hunk, "Next hunk")
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
local utils = require("utils")
|
||||
local lspsaga = require("lspsaga")
|
||||
|
||||
lspsaga.setup({
|
||||
@@ -8,3 +9,5 @@ lspsaga.setup({
|
||||
enable = true,
|
||||
},
|
||||
})
|
||||
|
||||
utils.nmap("<leader>t", "<cmd>Lspsaga term_toggle<CR>", "Open Floating Terminal")
|
||||
|
||||
@@ -16,3 +16,4 @@ telescope.setup(options)
|
||||
|
||||
utils.nmap("<leader>ff", builtin.find_files, "Find Files")
|
||||
utils.nmap("<leader>fg", builtin.live_grep, "Live Grep")
|
||||
utils.nmap("<leader>fb", builtin.buffers, "Opened Buffers")
|
||||
|
||||
@@ -18,7 +18,7 @@ local options = {
|
||||
vue = { "eslint_d" },
|
||||
},
|
||||
format_on_save = {
|
||||
timeout_ms = 5000,
|
||||
timeout_ms = 15000,
|
||||
lsp_format = "fallback",
|
||||
},
|
||||
}
|
||||
|
||||
@@ -42,6 +42,7 @@ vim.pack.add({
|
||||
{ src = "https://github.com/petertriho/nvim-scrollbar" },
|
||||
{ src = "https://github.com/j-hui/fidget.nvim" },
|
||||
{ src = "https://github.com/nvimdev/lspsaga.nvim" },
|
||||
{ src = "https://github.com/numtostr/comment.nvim" },
|
||||
|
||||
-- Framework specific
|
||||
{ src = "https://github.com/adibhanna/laravel.nvim" },
|
||||
|
||||
@@ -8,6 +8,10 @@
|
||||
"rev": "2cb62890cee636fe46722d03b7b2331e54fb3755",
|
||||
"src": "https://github.com/saghen/blink.lib"
|
||||
},
|
||||
"comment.nvim": {
|
||||
"rev": "e30b7f2008e52442154b66f7c519bfd2f1e32acb",
|
||||
"src": "https://github.com/numtostr/comment.nvim"
|
||||
},
|
||||
"conform.nvim": {
|
||||
"rev": "619363c30309d29ffa631e67c8183f2a72caa373",
|
||||
"src": "https://github.com/stevearc/conform.nvim"
|
||||
|
||||
Reference in New Issue
Block a user