From 54d8b950fd4f96ad4df046177526648739fec4e0 Mon Sep 17 00:00:00 2001 From: TheSoeren Date: Thu, 19 Sep 2024 15:00:31 +0200 Subject: [PATCH] add latex autocomplete --- lua/custom/plugins/cmp-vimtex.lua | 1 + lua/custom/plugins/vimtex.lua | 7 +++++++ lua/plugins.lua | 7 +++---- lua/set.lua | 2 +- 4 files changed, 12 insertions(+), 5 deletions(-) create mode 100644 lua/custom/plugins/cmp-vimtex.lua create mode 100644 lua/custom/plugins/vimtex.lua diff --git a/lua/custom/plugins/cmp-vimtex.lua b/lua/custom/plugins/cmp-vimtex.lua new file mode 100644 index 00000000..cc32af08 --- /dev/null +++ b/lua/custom/plugins/cmp-vimtex.lua @@ -0,0 +1 @@ +return { 'micangl/cmp-vimtex' } diff --git a/lua/custom/plugins/vimtex.lua b/lua/custom/plugins/vimtex.lua new file mode 100644 index 00000000..cfc0c37b --- /dev/null +++ b/lua/custom/plugins/vimtex.lua @@ -0,0 +1,7 @@ +return { + 'lervag/vimtex', + lazy = false, + init = function() + vim.g.vimtex_view_method = 'zathura' + end, +} diff --git a/lua/plugins.lua b/lua/plugins.lua index 7eae6f8a..5be05dce 100644 --- a/lua/plugins.lua +++ b/lua/plugins.lua @@ -160,7 +160,6 @@ require('lazy').setup({ 'vue', }, }, - angularls = {}, stylelint_lsp = { filetypes = { 'css', 'scss' }, root_dir = require('lspconfig').util.root_pattern('package.json', '.git'), @@ -200,7 +199,6 @@ require('lazy').setup({ fallbackFlags = { '--std=c++20' }, }, }, - marksman = {}, -- lua_ls = { @@ -316,7 +314,6 @@ require('lazy').setup({ json = { 'prettier' }, scss = { 'prettier' }, html = { 'prettier' }, - markdown = { 'prettier' }, -- Conform can also run multiple formatters sequentially -- python = { "isort", "black" }, -- @@ -437,6 +434,7 @@ require('lazy').setup({ { name = 'nvim_lsp' }, { name = 'luasnip' }, { name = 'path' }, + { name = 'vimtex' }, }, } end, @@ -501,6 +499,7 @@ require('lazy').setup({ auto_install = true, highlight = { enable = true, + disable = { 'latex' }, -- Some languages depend on vim's regex highlighting system (such as Ruby) for indent rules. -- If you are experiencing weird indenting issues, add the language to -- the list of additional_vim_regex_highlighting and disabled languages for indent. @@ -519,7 +518,7 @@ require('lazy').setup({ require 'kickstart.plugins.debug', -- require 'kickstart.plugins.indent_line', -- require 'kickstart.plugins.lint', - -- require 'kickstart.plugins.autopairs', + require 'kickstart.plugins.autopairs', require 'kickstart.plugins.neo-tree', -- require 'kickstart.plugins.gitsigns', -- adds gitsigns recommend keymaps diff --git a/lua/set.lua b/lua/set.lua index 88be80df..c90e7159 100644 --- a/lua/set.lua +++ b/lua/set.lua @@ -54,7 +54,7 @@ vim.opt.smartcase = true vim.opt.signcolumn = 'yes' -- Decrease update time -vim.opt.updatetime = 50 +vim.opt.updatetime = 150 -- Decrease mapped sequence wait time -- Displays which-key popup sooner