mirror of
https://github.com/iofq/nvim.nix.git
synced 2026-01-23 08:55:16 -06:00
fix ts
This commit is contained in:
parent
58c0637b78
commit
7165161856
10 changed files with 234 additions and 223 deletions
|
|
@ -82,24 +82,24 @@ vim.api.nvim_create_autocmd('FileType', {
|
|||
|
||||
map('[c', function()
|
||||
require('treesitter-context').go_to_context(vim.v.count1)
|
||||
end, { desc = 'jump to TS context' })
|
||||
end, { buffer = bufnr, desc = 'jump to TS context' })
|
||||
map(']f', function()
|
||||
require('nvim-treesitter-textobjects.move').goto_next_start('@function.outer', 'textobjects')
|
||||
end, { desc = 'next function def' })
|
||||
end, { buffer = bufnr, desc = 'next function def' })
|
||||
map('[f', function()
|
||||
require('nvim-treesitter-textobjects.move').goto_previous_start('@function.outer', 'textobjects')
|
||||
end, { desc = 'prev function def' })
|
||||
end, { buffer = bufnr, desc = 'prev function def' })
|
||||
map(']a', function()
|
||||
require('nvim-treesitter-textobjects.move').goto_next_start('@parameter.inner', 'textobjects')
|
||||
end, { desc = 'next param def' })
|
||||
end, { buffer = bufnr, desc = 'next param def' })
|
||||
map('[a', function()
|
||||
require('nvim-treesitter-textobjects.move').goto_previous_start('@parameter.inner', 'textobjects')
|
||||
end, { desc = 'prev param def' })
|
||||
end, { buffer = bufnr, desc = 'prev param def' })
|
||||
map('a]', function()
|
||||
require('nvim-treesitter-textobjects.swap').swap_next('@parameter.inner')
|
||||
end, { desc = 'swap next arg' })
|
||||
end, { buffer = bufnr, desc = 'swap next arg' })
|
||||
map('a[', function()
|
||||
require('nvim-treesitter-textobjects.swap').swap_previous('@parameter.inner')
|
||||
end, { desc = 'swap prev arg' })
|
||||
end, { buffer = bufnr, desc = 'swap prev arg' })
|
||||
end,
|
||||
})
|
||||
|
|
|
|||
|
|
@ -19,7 +19,6 @@ vim.opt.tabstop = 2 -- 2 space tabs are based
|
|||
vim.opt.updatetime = 250 -- decrease update time
|
||||
vim.opt.virtualedit = 'onemore'
|
||||
vim.opt.winborder = 'rounded'
|
||||
vim.cmd('colorscheme iofq')
|
||||
|
||||
-- Configure Neovim diagnostic messages
|
||||
vim.diagnostic.config {
|
||||
|
|
@ -32,5 +31,7 @@ vim.diagnostic.config {
|
|||
source = 'if_many',
|
||||
},
|
||||
}
|
||||
require('config.keymaps')
|
||||
require('config.autocmd')
|
||||
vim.schedule(function()
|
||||
require('config.autocmd')
|
||||
require('config.keymaps')
|
||||
end)
|
||||
|
|
|
|||
|
|
@ -8,6 +8,7 @@ return {
|
|||
'phpactor',
|
||||
'gopls',
|
||||
'lua_ls',
|
||||
'basedpyright',
|
||||
}
|
||||
|
||||
vim.api.nvim_create_autocmd('LspAttach', {
|
||||
|
|
|
|||
|
|
@ -1,7 +1,8 @@
|
|||
return {
|
||||
{
|
||||
'iofq/dart.nvim',
|
||||
event = 'VeryLazy',
|
||||
lazy = false,
|
||||
priority = 1001,
|
||||
config = true,
|
||||
},
|
||||
{
|
||||
|
|
@ -13,15 +14,12 @@ return {
|
|||
'nvim-treesitter/nvim-treesitter',
|
||||
event = 'VeryLazy',
|
||||
branch = 'main',
|
||||
main = 'nvim-treesitter.configs',
|
||||
config = true,
|
||||
dependencies = {
|
||||
{
|
||||
'nvim-treesitter/nvim-treesitter-textobjects',
|
||||
branch = 'main',
|
||||
config = true,
|
||||
},
|
||||
'RRethy/nvim-treesitter-textsubjects',
|
||||
{
|
||||
'nvim-treesitter/nvim-treesitter-context',
|
||||
opts = {
|
||||
|
|
@ -49,6 +47,7 @@ return {
|
|||
'sindrets/diffview.nvim',
|
||||
event = 'VeryLazy',
|
||||
opts = {
|
||||
use_icons = false,
|
||||
enhanced_diff_hl = true,
|
||||
default_args = {
|
||||
DiffviewOpen = { '--imply-local' },
|
||||
|
|
@ -105,12 +104,16 @@ return {
|
|||
{
|
||||
'stevearc/quicker.nvim',
|
||||
event = 'VeryLazy',
|
||||
config = true,
|
||||
opts = {
|
||||
follow = {
|
||||
enabled = true,
|
||||
},
|
||||
},
|
||||
keys = {
|
||||
{
|
||||
'<leader>qf',
|
||||
function()
|
||||
require('quicker').toggle()
|
||||
require('quicker').toggle { max_height = 20 }
|
||||
end,
|
||||
desc = 'Toggle qflist',
|
||||
},
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue