feat: set sensible vim.options

This commit is contained in:
Matej Janezic 2025-10-05 21:00:03 +02:00
parent 6cc1c703a5
commit 1057b83693
Signed by: janezicmatej
GPG Key ID: 4298E230ED37B2C0
2 changed files with 39 additions and 0 deletions

View File

@ -1,2 +1,4 @@
-- set vim options
require("config.options")
-- import plugins -- import plugins
require("config.plugins") require("config.plugins")

37
lua/config/options.lua Normal file
View File

@ -0,0 +1,37 @@
vim.g.mapleader = " "
-- disable netrw
vim.g.loaded_netrw = 1
vim.g.loaded_netrwPlugin = 1
-- general
vim.o.backup = false
vim.o.mouse = ""
-- TODO:(janezicmatej) i think mouse scroll is binded to up/down and this
-- deosn't always work
vim.o.mousescroll = "ver:0,hor:0"
vim.o.writebackup = false
vim.o.undofile = true
-- ui
vim.o.breakindent = true
vim.o.colorcolumn = "+1"
vim.o.number = true
vim.o.cursorline = true
vim.o.relativenumber = true
vim.o.splitright = true
vim.o.splitbelow = true
vim.o.signcolumn = "yes"
vim.o.wrap = false
vim.o.winborder = "double"
-- editing
vim.o.autoindent = true
vim.o.expandtab = true
vim.o.ignorecase = true
vim.o.smartcase = true
vim.o.completeopt = "menuone,noselect,fuzzy,nosort"
-- default plus added dash
vim.o.iskeyword = "@,48-57,_,192-255,-"