48 lines
1007 B
Lua
48 lines
1007 B
Lua
local set = vim.opt
|
|
|
|
set.mouse = 'a'
|
|
set.encoding = 'UTF-8'
|
|
set.fileencoding = 'UTF-8'
|
|
|
|
set.number = true
|
|
set.relativenumber = true
|
|
set.showcmd = true
|
|
vim.o.syntax = true
|
|
|
|
set.ignorecase = true
|
|
set.smartcase = true
|
|
|
|
set.cursorline = true
|
|
-- bold line number at cursor
|
|
vim.cmd [[ highlight CursorLineNr cterm=bold ]]
|
|
|
|
set.linebreak = true
|
|
|
|
-- special characters
|
|
set.list = true
|
|
set.listchars = 'tab:→ ,eol:↲,nbsp:␣,trail:•,extends:⟩,precedes:⟨'
|
|
|
|
set.tabstop = 4
|
|
set.shiftwidth = 4
|
|
vim.o.expandtab = false
|
|
vim.o.smartindent = true
|
|
|
|
set.swapfile = false
|
|
|
|
-- spellcheck (enable with `set spell`)
|
|
vim.o.spelllang = 'cs,en_gb'
|
|
vim.cmd [[ hi SpellBad cterm=bold ctermbg=red ctermfg=white ]]
|
|
|
|
-- cursor padding from top and bottom
|
|
vim.o.scrolloff = 5
|
|
|
|
-- better navigation in split windows
|
|
vim.keymap.set('n', '<C-h>', '<C-w>h')
|
|
vim.keymap.set('n', '<C-j>', '<C-w>j')
|
|
vim.keymap.set('n', '<C-k>', '<C-w>k')
|
|
vim.keymap.set('n', '<C-h>', '<C-w>l')
|
|
|
|
-- colorscheme
|
|
vim.cmd [[ color base16-default-dark ]]
|
|
|