68 lines
1.5 KiB
Lua
68 lines
1.5 KiB
Lua
|
-- [[ Setting options ]]
|
||
|
--- See `:help vim.opt`
|
||
|
--- For more options, see `:help option-list`
|
||
|
|
||
|
-- Show Line Numbers
|
||
|
vim.opt.number = true
|
||
|
vim.opt.relativenumber = true
|
||
|
--- Use relative line numbers (normal would be vim.opt.number = true)
|
||
|
|
||
|
-- Default Tabbing
|
||
|
vim.opt.tabstop = 4
|
||
|
vim.opt.shiftwidth = 4
|
||
|
|
||
|
-- Line Breaking
|
||
|
vim.opt.linebreak = true
|
||
|
|
||
|
-- Enable Mouse Mode
|
||
|
vim.opt.mouse = 'a'
|
||
|
--- Can be useful for resizing splits for example!
|
||
|
|
||
|
-- Don't Show Mode
|
||
|
vim.opt.showmode = false
|
||
|
--- It's already in the status line
|
||
|
|
||
|
-- Sync Clipboard btwn OS and Neovim
|
||
|
vim.opt.clipboard = 'unnamedplus'
|
||
|
--- See `:help 'clipboard'`
|
||
|
|
||
|
-- "Indent" Decision Trigger on Break
|
||
|
vim.opt.breakindent = true
|
||
|
|
||
|
-- Save Undo History
|
||
|
vim.opt.undofile = true
|
||
|
|
||
|
-- Search Case
|
||
|
vim.opt.ignorecase = true
|
||
|
vim.opt.smartcase = true
|
||
|
--- Ignore case...
|
||
|
--- ...UNLESS \C or capital letter in search
|
||
|
|
||
|
-- Keep Signcolumn On
|
||
|
vim.opt.signcolumn = 'yes'
|
||
|
|
||
|
-- Decrease Update Time
|
||
|
vim.opt.updatetime = 250
|
||
|
vim.opt.timeoutlen = 300
|
||
|
|
||
|
-- Configure New Split Behavior
|
||
|
vim.opt.splitright = true
|
||
|
vim.opt.splitbelow = true
|
||
|
--- Splits will appear below to the right, which feels natural
|
||
|
|
||
|
-- Configure Whitespace Character Representations
|
||
|
vim.opt.list = true
|
||
|
vim.opt.listchars = { tab = '» ', trail = '·', nbsp = '␣' }
|
||
|
--- See `:help 'list'`...
|
||
|
--- ...and `:help 'listchars'`
|
||
|
|
||
|
-- Preview Potential Substitutions Live
|
||
|
vim.opt.inccommand = 'split'
|
||
|
--- Shows what would be auto-completed
|
||
|
|
||
|
-- Highlight Current Line (containing Cursor)
|
||
|
vim.opt.cursorline = true
|
||
|
|
||
|
-- Minimal # Screen Lines Above/Below Cursor
|
||
|
vim.opt.scrolloff = 10
|