-- Map Leader vim.g.mapleader = ' ' vim.g.maplocalleader = ' ' -- Disable built-in plugins vim.loader.enable() vim.g.loaded_gzip = 1 vim.g.loaded_tar = 1 vim.g.loaded_tarPlugin = 1 vim.g.loaded_zip = 1 vim.g.loaded_zipPlugin = 1 vim.g.loaded_getscript = 1 vim.g.loaded_getscriptPlugin = 1 vim.g.loaded_vimball = 1 vim.g.loaded_vimballPlugin = 1 vim.g.loaded_matchit = 1 vim.g.loaded_2html_plugin = 1 vim.g.loaded_rrhelper = 1 vim.g.loaded_matchparen = 1 vim.g.loaded_tutor_mode_plugin = 1 vim.g.loaded_spellfile_plugin = 1 vim.g.loaded_logipat = 1 vim.g.loaded_rplugin = 1 vim.g.loaded_netrw = 1 -- use nvim-tree instead vim.g.loaded_netrwPlugin = 1 -- UI vim.g.have_nerd_font = true vim.opt.termguicolors = false vim.opt.textwidth = 100 vim.opt.colorcolumn = '+0' vim.opt.signcolumn = 'no' vim.opt.number = true vim.opt.relativenumber = true vim.opt.cursorline = true vim.opt.ruler = false vim.opt.winborder = 'rounded' vim.opt.guicursor = 'n-v-i-c:block' vim.opt.laststatus = 3 vim.opt.statusline = '── %f %h%w%m%r %= [%l,%c-%L] ──' vim.opt.fillchars = { stl = '─', stlnc = '─', horiz = '─', horizdown = '─', horizup = '─', vert = '│', vertleft = '│', vertright = '│', verthoriz = '│', } -- Wrap vim.opt.wrap = false vim.opt.linebreak = true vim.opt.breakindent = true -- Indent vim.opt.shiftwidth = 2 -- Number of spaces to use for (auto)indent vim.opt.tabstop = 2 -- Number of spaces that a in file counts for vim.opt.softtabstop = 2 -- Number of spaces when pressing in insert mode vim.opt.expandtab = true -- Use spaces instead of literal tab characters vim.opt.autoindent = true -- Copy indent from the current line when starting a new one vim.opt.smartindent = true -- Automatically inserts indents in code blocks (for C-like languages) -- Scroll and mouse vim.opt.scrolloff = 10 vim.opt.sidescrolloff = 5 vim.opt.mousescroll = 'hor:1,ver:5' vim.opt.mouse = 'a' -- Enable mouse support -- Search vim.opt.ignorecase = true vim.opt.smartcase = true -- Override ignorecase if search contains upper case chars vim.opt.inccommand = 'split' -- Live substitution preview vim.opt.completeopt = { 'fuzzy', 'menuone', 'popup', 'noselect' } -- Splits vim.opt.splitright = true vim.opt.splitbelow = true -- Persistence vim.opt.undofile = true vim.opt.swapfile = false -- Tweaks vim.opt.updatetime = 1000 vim.opt.timeout = true vim.opt.ttimeout = true vim.opt.timeoutlen = 500 vim.opt.ttimeoutlen = 10 -- Clipboard if vim.env.CONTAINER then vim.g.clipboard = { name = 'osc52', copy = { ['+'] = require('vim.ui.clipboard.osc52').copy('+'), ['*'] = require('vim.ui.clipboard.osc52').copy('*'), }, paste = { ['+'] = require('vim.ui.clipboard.osc52').paste('+'), ['*'] = require('vim.ui.clipboard.osc52').paste('*'), }, } end -- require('custom.navigation') -- require('custom.tabline').setup()