absvim/lua/options.lua

59 lines
1.4 KiB
Lua
Raw Normal View History

2023-03-08 20:06:54 +00:00
-- Map leader
vim.g.mapleader = " "
2023-02-28 02:27:44 +00:00
-- colors
vim.o.termguicolors = true
-- Better display for messages
vim.o.cmdheight = 1
-- You will have bad experience for diagnostic messages when it's default 4000.
2023-03-06 06:40:41 +00:00
vim.o.updatetime = 100
2023-02-28 02:27:44 +00:00
vim.o.mmp = 5000
-- don't give |ins-completion-menu| messages.
vim.o.hidden = true
2023-07-11 03:43:47 +00:00
vim.o.signcolumn = "yes"
vim.o.encoding = "utf-8"
vim.o.shortmess = "c"
2023-02-28 02:27:44 +00:00
vim.o.autoread = true
2023-07-11 03:43:47 +00:00
vim.o.backspace = "indent,eol,start"
2023-02-28 02:27:44 +00:00
vim.o.ruler = true
vim.o.showmode = true
vim.o.history = 1000
vim.o.hidden = true
vim.o.ignorecase = true
vim.o.smartcase = true
vim.o.hlsearch = true
vim.o.incsearch = true
vim.o.showmatch = true
vim.o.laststatus = 2
vim.o.autoindent = true
vim.o.cindent = true
vim.o.shiftwidth = 2
vim.o.softtabstop = 2
vim.o.tabstop = 2
vim.o.expandtab = true
vim.o.scrolloff = 5
2023-07-11 03:43:47 +00:00
vim.o.foldmethod = "indent"
2023-02-28 02:27:44 +00:00
vim.o.foldlevel = 99
vim.wo.wrap = false
vim.o.showcmd = true
vim.o.number = true
vim.o.relativenumber = true
2023-07-11 03:43:47 +00:00
vim.o.mouse = "a"
2023-02-28 02:27:44 +00:00
vim.o.redrawtime = 10000
2023-07-11 03:43:47 +00:00
vim.o.inccommand = "split"
2023-02-28 02:27:44 +00:00
---- Sync " and + registers
2023-07-11 03:43:47 +00:00
vim.o.clipboard = "unnamedplus"
2023-02-28 02:27:44 +00:00
-- show completion options on <TAB>
vim.o.wildmenu = true
-- complete only up to the point of ambiguity
2023-07-11 03:43:47 +00:00
vim.o.wildmode = "list:longest"
2023-02-28 02:27:44 +00:00
2023-07-11 03:43:47 +00:00
vim.opt.backupdir = os.getenv("XDG_CACHE_HOME") .. "/nvim/backup//"
vim.o.directory = os.getenv("XDG_CACHE_HOME") .. "/nvim/swap//"
vim.o.undodir = os.getenv("XDG_CACHE_HOME") .. "/nvim/undo//"
2023-02-28 02:27:44 +00:00
vim.o.undofile = true