setup: add options

This commit is contained in:
Abdulrahman Sheikho 2026-03-08 08:14:07 +03:00
parent 53990b306f
commit b6b171e414
1 changed files with 19 additions and 2 deletions

View File

@ -7,7 +7,7 @@
vim.o.number = true vim.o.number = true
-- You can also add relative line numbers, to help with jumping. -- You can also add relative line numbers, to help with jumping.
-- Experiment for yourself to see if you like it! -- Experiment for yourself to see if you like it!
-- vim.o.relativenumber = true vim.o.relativenumber = true
-- Enable mouse mode, can be useful for resizing splits for example! -- Enable mouse mode, can be useful for resizing splits for example!
vim.o.mouse = 'a' vim.o.mouse = 'a'
@ -64,9 +64,26 @@ vim.o.inccommand = 'split'
vim.o.cursorline = true vim.o.cursorline = true
-- Minimal number of screen lines to keep above and below the cursor. -- Minimal number of screen lines to keep above and below the cursor.
vim.o.scrolloff = 10 vim.o.scrolloff = 5
-- if performing an operation that would fail due to unsaved changes in the buffer (like `:q`), -- if performing an operation that would fail due to unsaved changes in the buffer (like `:q`),
-- instead raise a dialog asking if you wish to save the current file(s) -- instead raise a dialog asking if you wish to save the current file(s)
-- See `:help 'confirm'` -- See `:help 'confirm'`
vim.o.confirm = true vim.o.confirm = true
-- set linebreak to true to break lines according to word-boundary rather than last character
vim.o.linebreak = true
-- set tabs
-- A tab character looks like 4 spaces
vim.o.tabstop = 4
-- Size of an indent
vim.o.shiftwidth = 4
-- Number of spaces tabs count for a while performing editing operations
vim.o.softtabstop = 4
-- Turn tabs into spaces
vim.o.expandtab = true
-- set spellchecking
vim.o.spell = true
vim.o.spelllang = 'en_us'