aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCrony Akatsuki <crony@cronyakatsuki.xyz>2025-10-21 10:07:48 +0200
committerCrony Akatsuki <crony@cronyakatsuki.xyz>2025-10-21 10:07:48 +0200
commit3a99d36890ae5ddbdc9c194b40e91d665cae1874 (patch)
treef36d32126224ac157d9e6635639db17ba66092a9
parentd18286f7fcd2b1ce3756f3e2728de05cc0eff3d8 (diff)
downloadnvim-3a99d36890ae5ddbdc9c194b40e91d665cae1874.zip
nvim-3a99d36890ae5ddbdc9c194b40e91d665cae1874.tar.gz
feat(settings): add more settings.
-rw-r--r--lua/config/settings.lua71
1 files changed, 68 insertions, 3 deletions
diff --git a/lua/config/settings.lua b/lua/config/settings.lua
index 3fdff37..d901684 100644
--- a/lua/config/settings.lua
+++ b/lua/config/settings.lua
@@ -2,6 +2,12 @@
vim.opt.number = true
vim.opt.relativenumber = true
+-- highlight cursorline
+vim.opt.cursorline = true
+
+-- highlight column 80
+vim.opt.colorcolumn = "80"
+
-- make splits open on bottom and right
vim.opt.splitbelow = true
vim.opt.splitright = true
@@ -9,13 +15,17 @@ vim.opt.splitright = true
-- disable line wrapping
vim.opt.wrap = false
--- setup tabs nicelly
+-- setup tabs and indenting
vim.opt.expandtab = true
+vim.opt.smartindent = true
+vim.opt.autoindent = true
vim.opt.tabstop = 2
vim.opt.shiftwidth = 2
+vim.opt.softtabstop = 2
-- setup a nice scrolloff value
vim.opt.scrolloff = 20
+vim.opt.sidescrolloff = 10
-- make virtual edit work for blocks
vim.opt.virtualedit = "block"
@@ -23,8 +33,63 @@ vim.opt.virtualedit = "block"
-- make :s and others open a split
vim.opt.inccommand = "split"
--- ignore case
+-- search settings
vim.opt.ignorecase = true
+vim.opt.smartcase = true
+
+-- matching bracket settings
+vim.opt.showmatch = true
+vim.opt.matchtime = 2
+
+-- commandline settings
+vim.opt.cmdheight = 1
+vim.opt.showmode = false
+
+-- popup settings
+vim.opt.pumheight = 10
+vim.opt.pumblend = 10
+vim.opt.winblend = 0
+
+-- concealing settings
+vim.opt.conceallevel = 0
+vim.opt.concealcursor = ""
+
+-- redraw lazilly
+vim.opt.lazyredraw = true
--- disable neovim swap files
+-- lower syntax highlighing for performance
+vim.opt.synmaxcol = 300
+
+-- better completion options
+vim.opt.completeopt = "menuone,noinsert,noselect"
+
+-- enable signcolumn
+vim.opt.signcolumn = "yes"
+
+-- enable rounded borders
+vim.opt.winborder = "rounded"
+
+-- better file handling
+vim.opt.backup = false
+vim.opt.writebackup = false
vim.opt.swapfile = false
+vim.opt.undofile = true
+vim.opt.undodir = vim.fn.expand("~/.local/state/nvim/undo")
+vim.opt.autoread = true
+vim.opt.autowrite = true
+
+-- durations for completion and other stuff
+vim.opt.updatetime = 300
+vim.opt.timeoutlen = 500
+vim.opt.ttimeoutlen = 0
+
+-- change some behaviour settings
+vim.opt.hidden = true
+vim.opt.errorbells = false
+vim.opt.backspace = "indent,eol,start"
+vim.opt.autochdir = false
+vim.opt.iskeyword:append("-") -- treat dash as part of the word
+vim.opt.path:append("**") -- include subdirectories in search
+vim.opt.selection = "exclusive"
+vim.opt.modifiable = true
+vim.opt.encoding = "UTF8"