From 22f40b3d4016545bf8ea20019189933fc24b5ff7 Mon Sep 17 00:00:00 2001 From: flin16 Date: Sun, 25 May 2025 23:24:00 -0500 Subject: [PATCH] No big change --- lazy-lock.json | 1 + lazyvim.json | 3 ++- lua/config/keymaps.lua | 2 +- lua/plugins/example.lua | 6 ++++++ lua/telescope/_extensions/tex_toc.lua | 0 5 files changed, 10 insertions(+), 2 deletions(-) create mode 100644 lua/telescope/_extensions/tex_toc.lua diff --git a/lazy-lock.json b/lazy-lock.json index 42bd496..47e7b3a 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -33,6 +33,7 @@ "nvim-lspconfig": { "branch": "master", "commit": "3ea99227e316c5028f57a4d86a1a7fd01dd876d0" }, "nvim-nio": { "branch": "master", "commit": "21f5324bfac14e22ba26553caf69ec76ae8a7662" }, "nvim-treesitter": { "branch": "master", "commit": "42fc28ba918343ebfd5565147a42a26580579482" }, + "nvim-treesitter-context": { "branch": "master", "commit": "404502e607c3b309e405be9112c438c721153372" }, "nvim-treesitter-textobjects": { "branch": "master", "commit": "0f051e9813a36481f48ca1f833897210dbcfffde" }, "nvim-ts-autotag": { "branch": "main", "commit": "a1d526af391f6aebb25a8795cbc05351ed3620b5" }, "persistence.nvim": { "branch": "main", "commit": "166a79a55bfa7a4db3e26fc031b4d92af71d0b51" }, diff --git a/lazyvim.json b/lazyvim.json index 8893f66..2f6f577 100644 --- a/lazyvim.json +++ b/lazyvim.json @@ -7,7 +7,8 @@ "lazyvim.plugins.extras.lang.markdown", "lazyvim.plugins.extras.lang.python", "lazyvim.plugins.extras.lang.tex", - "lazyvim.plugins.extras.test.core" + "lazyvim.plugins.extras.test.core", + "lazyvim.plugins.extras.ui.treesitter-context" ], "install_version": 8, "news": { diff --git a/lua/config/keymaps.lua b/lua/config/keymaps.lua index f1c0703..dfcaf79 100644 --- a/lua/config/keymaps.lua +++ b/lua/config/keymaps.lua @@ -44,7 +44,7 @@ map_all_mode("", function() end end, { desc = "Close current tab" }) map_all_mode("", function() vim.cmd("undo") end) -vim.keymap.set("i", "", '"+gP') +vim.keymap.set("i", "", '"+p') vim.keymap.set("c", "", "+") vim.keymap.set("n", "", '"+p', { desc = "Paste from clipboard" }) vim.keymap.set("v", "", '"_d"+gP', { desc = "Remove the selected part and paste from system clipboard." }) diff --git a/lua/plugins/example.lua b/lua/plugins/example.lua index 1fae129..ad0daa9 100644 --- a/lua/plugins/example.lua +++ b/lua/plugins/example.lua @@ -21,6 +21,12 @@ return { vim.g.vimtex_view_method = "skim" vim.g.vimtex_view_skim_sync = 1 vim.g.vimtex_view_skim_activate = 1 + vim.g.vimtex_toc_custom_matchers = { + { title = "Theorem", re = [[\v^\s*\\begin\{theorem\}]] }, + { title = "Lemma", re = [[\v^\s*\\begin\{lemma\}]] }, + { title = "Corollary", re = [[\v^\s*\\begin\{corollary\}]] }, + { title = "Definition", re = [[\v^\s*\\begin\{definition\}]] }, + } end }, { diff --git a/lua/telescope/_extensions/tex_toc.lua b/lua/telescope/_extensions/tex_toc.lua new file mode 100644 index 0000000..e69de29