This repository has been archived on 2023-12-28. You can view files and clone it, but cannot push or open issues or pull requests.
nvim-config/lua/config.lua

42 lines
990 B
Lua
Raw Permalink Normal View History

2022-11-01 17:34:57 +01:00
vim.o.mouse = 'a'
vim.o.encoding = 'UTF-8'
vim.o.fileencoding = 'UTF-8'
vim.o.number = true
vim.o.relativenumber = true
vim.o.showcmd = true
vim.o.syntax = true
vim.o.ignorecase = true
vim.o.smartcase = true
vim.o.cursorline = true
-- bold line number at cursor
vim.cmd [[ highlight CursorLineNr cterm=bold ]]
vim.o.linebreak = true
-- special characters
vim.o.list = true
vim.o.listchars = 'tab:→ ,eol:↲,nbsp:␣,trail:•,extends:⟩,precedes:⟨'
vim.o.tabstop = 4
vim.o.shiftwidth = 4
vim.o.expandtab = false
vim.o.smartindent = true
-- 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 ]]