vim.schedule(function() vim.opt.clipboard = "unnamedplus" end) vim.g.have_nerd_fonts = true vim.o.fileencoding = "utf-8" vim.o.mouse = "a" -- turn on mouse interaction vim.o.shell = "nushell" vim.o.signcolumn = "yes" vim.o.termguicolors = true -- Enable GUI colors for the terminal to get truecolor vim.opt.conceallevel = 0 vim.opt.title = true -- set the title of window to the value of the titlestring vim.opt.titlestring = "%<%F%=%l/%L - nvim" -- what the title of the window will be set to vim.o.guicursor = table.concat({ "n-v-c:block-Cursor/lCursor-blinkwait1000-blinkon100-blinkoff100", "i-ci:ver25-Cursor/lCursor-blinkwait1000-blinkon100-blinkoff100", "r:hor50-Cursor/lCursor-blinkwait100-blinkon100-blinkoff100", }, ",") vim.o.autoindent = true vim.o.expandtab = false vim.o.list = true -- show hidden characters by default vim.o.shiftwidth = 4 vim.o.shiftwidth = 4 vim.o.smartindent = true vim.o.smarttab = true -- / indent/dedent in leading whitespace vim.o.softtabstop = 4 vim.o.tabstop = 4 vim.o.textwidth = 100 vim.o.updatetime = 100 -- CursorHold interval vim.opt.breakindent = true vim.opt.completeopt = { "menu", "menuone", "noselect", "noinsert", "preview" } -- completion options vim.opt.grepformat = "%f:%l:%c:%m" vim.opt.grepprg = "rg --vimgrep" vim.opt.hidden = true -- required to keep multiple buffers and open multiple buffers vim.opt.inccommand = "split" vim.opt.linebreak = true vim.opt.shortmess:append("c") vim.opt.smartcase = true vim.opt.virtualedit = "block" vim.opt.wrap = true vim.o.undofile = true vim.o.undodir = "/home/petri/.config/nvim/undo/" vim.o.backupdir = "/home/petri/.config/nvim/backup/" vim.o.directory = "/home/petri/.config/nvim//swp/" vim.o.colorcolumn = "100" vim.o.cursorline = true -- highlight current line vim.o.hlsearch = true -- highlighted search results vim.o.ignorecase = true -- ignore case sensetive while searching vim.o.incsearch = true -- incremental search vim.o.number = true -- show line numbers vim.o.relativenumber = true -- relative line numbers vim.o.showmode = false -- we are already showing mode vim.opt.matchtime = 2 -- how long to show matching bracket vim.opt.pumblend = 10 -- popup menu transparency vim.opt.showmatch = true -- show matching bracket vim.opt.synmaxcol = 300 vim.opt.winblend = 0 vim.opt.winborder = "rounded" vim.opt.autoread = true vim.opt.path:append("**") -- include subdirectories in search vim.opt.selection = "exclusive" -- Selection behavior vim.opt.showtabline = 2 -- show when multiple open vim.opt.swapfile = false vim.opt.foldenable = true -- Enable folding vim.opt.foldlevel = 99 -- Start with all folds open vim.opt.foldmethod = "syntax" vim.opt.scrolloff = 8 vim.opt.sidescrolloff = 8 vim.opt.backspace = "indent,start,eol" -- make backspace behave like normal again vim.opt.formatoptions:remove({ "c", "t" }) vim.opt.laststatus = 2 -- always show status line vim.opt.lazyredraw = false -- faster scrolling vim.opt.listchars = { tab = "» ", trail = "·", nbsp = "␣" } vim.opt.splitbelow = true -- open horizontal splits below current window vim.opt.splitright = true -- open vertical splits to the right of the current window vim.opt.wildignore = vim.opt.wildignore + "*.o,*.rej,*.so" -- patterns to ignore during file-navigation vim.opt.spell = false vim.opt.spelllang = "en" vim.opt.wildignore:append({ "*.pyc" }) vim.opt.wildmenu = true vim.opt.wildmode = "longest:full,full" vim.opt.diffopt:append("linematch:60") vim.opt.redrawtime = 10000 vim.opt.maxmempattern = 50000 vim.cmd.colorscheme("nord")