51 lines
1 KiB
Lua
51 lines
1 KiB
Lua
local go = vim.g
|
|
local o = vim.opt
|
|
|
|
-- Optimizations on startup
|
|
vim.loader.enable()
|
|
|
|
-- LazyVim related options
|
|
vim.g.lazyvim_statuscolumn.folds_open = true
|
|
vim.g.lazyvim_statuscolumn.folds_githl = true
|
|
|
|
-- Define leader key
|
|
go.mapleader = " "
|
|
go.maplocalleader = "\\"
|
|
|
|
-- Autoformat on save (Global)
|
|
go.autoformat = true
|
|
|
|
-- Font
|
|
go.gui_font_default_size = 10
|
|
go.gui_font_size = go.gui_font_default_size
|
|
go.gui_font_face = "JetBrainsMono Nerd Font"
|
|
|
|
-- Enable EditorConfig integration
|
|
go.editorconfig = true
|
|
|
|
-- Root dir detection
|
|
go.root_spec = {
|
|
"lsp",
|
|
{ ".git", "lua", ".obsidian", "package.json", "Makefile", "go.mod", "cargo.toml", "pyproject.toml", "src" },
|
|
"cwd",
|
|
}
|
|
|
|
-- Disable annoying cmd line stuff
|
|
o.showcmd = false
|
|
o.laststatus = 0
|
|
o.cmdheight = 0
|
|
|
|
-- Enable spell checking
|
|
o.spell = true
|
|
o.spelllang = { "en" }
|
|
|
|
-- Backspacing and indentation when wrapping
|
|
o.backspace = { "start", "eol", "indent" }
|
|
o.breakindent = true
|
|
|
|
-- Smoothscroll
|
|
if vim.fn.has("nvim-0.10") == 1 then
|
|
o.smoothscroll = true
|
|
end
|
|
|
|
o.conceallevel = 2
|