Personal LazyVim config: vimtex, LTeX, Vale, prose settings

This commit is contained in:
YannAhlgrim
2026-06-27 19:07:03 +02:00
parent 803bc181d7
commit 8ba8365eb1
15 changed files with 507 additions and 0 deletions
+18
View File
@@ -6,3 +6,21 @@
--
-- Or remove existing autocmds by their group name (which is prefixed with `lazyvim_` for the defaults)
-- e.g. vim.api.nvim_del_augroup_by_name("lazyvim_wrap_spell")
vim.api.nvim_create_autocmd("TermOpen", {
group = vim.api.nvim_create_augroup("term_settings", { clear = true }),
callback = function()
vim.opt_local.wrap = true
-- vim.opt_local.spell = false -- Optional: disable spellcheck in terminal
end,
})
-- Prose/LaTeX settings: spell-checking + visual word-wrap
vim.api.nvim_create_autocmd("FileType", {
group = vim.api.nvim_create_augroup("prose_settings", { clear = true }),
pattern = { "tex", "plaintex", "markdown", "text" },
callback = function()
vim.opt_local.spell = true
vim.opt_local.wrap = true
vim.opt_local.linebreak = true
end,
})
+42
View File
@@ -1,3 +1,45 @@
-- Keymaps are automatically loaded on the VeryLazy event
-- Default keymaps that are always set: https://github.com/LazyVim/LazyVim/blob/main/lua/lazyvim/config/keymaps.lua
-- Add any additional keymaps here
-- This file is automatically loaded by lazyvim.config.init
local map = vim.keymap.set
-- DAP (Debug Adapter Protocol)
-- Note: LazyVim uses <leader>d for Debugging by default,
-- but these will override/augment the defaults.
map("n", "<leader>dl", function()
require("dap").step_into()
end, { desc = "Debugger step into" })
map("n", "<leader>dj", function()
require("dap").step_over()
end, { desc = "Debugger step over" })
map("n", "<leader>dk", function()
require("dap").step_out()
end, { desc = "Debugger step out" })
map("n", "<leader>dc", function()
require("dap").continue()
end, { desc = "Debugger continue" })
map("n", "<leader>db", function()
require("dap").toggle_breakpoint()
end, { desc = "Debugger toggle breakpoint" })
map("n", "<leader>dd", function()
require("dap").set_breakpoint(vim.fn.input("Breakpoint condition: "))
end, { desc = "Debugger set conditional breakpoint" })
map("n", "<leader>de", function()
require("dap").terminate()
end, { desc = "Debugger reset" })
map("n", "<leader>dr", function()
require("dap").run_last()
end, { desc = "Debugger run last" })
-- Rustaceanvim
map("n", "<leader>dt", "<cmd>RustLsp testables<cr>", { desc = "Debugger testables" })
-- Copilot toggle (inline suggestions + blink/cmp source)
map("n", "<leader>ua", function()
vim.g.copilot_enabled = not vim.g.copilot_enabled
require("copilot.suggestion").toggle_auto_trigger()
local state = vim.g.copilot_enabled and "enabled" or "disabled"
vim.notify("Copilot " .. state, vim.log.levels.INFO)
end, { desc = "Toggle Copilot" })
+12
View File
@@ -1,3 +1,15 @@
-- Options are automatically loaded before lazy.nvim startup
-- Default options that are always set: https://github.com/LazyVim/LazyVim/blob/main/lua/lazyvim/config/options.lua
-- Add any additional options here
-- VimTeX local leader (must be set before plugins load)
vim.g.maplocalleader = ","
vim.diagnostic.config({
virtual_text = false,
virtual_lines = true,
})
-- Spell-checking files (spell itself is enabled per filetype in autocmds.lua)
vim.opt.spelllang = { "en_us" }
vim.opt.spellfile = vim.fn.expand("~/.config/nvim/spell/en.utf-8.add")