init.lua 799 B

12345678910111213141516171819202122232425
  1. vim.g.vimtex_compiler_method = "latexmk"
  2. vim.g.vimtex_view_method = "zathura"
  3. vim.g.vimtex_fold_enabled = 0
  4. O.user_which_key["L"] = {
  5. name = "+Latex",
  6. c = { "<cmd>VimtexCompile<cr>", "Toggle Compilation Mode" },
  7. f = { "<cmd>call vimtex#fzf#run()<cr>", "Fzf Find" },
  8. i = { "<cmd>VimtexInfo<cr>", "Project Information" },
  9. s = { "<cmd>VimtexStop<cr>", "Stop Project Compilation" },
  10. t = { "<cmd>VimtexTocToggle<cr>", "Toggle Table Of Content" },
  11. v = { "<cmd>VimtexView<cr>", "View PDF" },
  12. }
  13. -- Compile on initialization, cleanup on quit
  14. vim.api.nvim_exec(
  15. [[
  16. augroup vimtex_event_1
  17. au!
  18. au User VimtexEventQuit call vimtex#compiler#clean(0)
  19. au User VimtexEventInitPost call vimtex#compiler#compile()
  20. augroup END
  21. ]],
  22. false
  23. )