2024-02-29 16:33:20 +00:00
|
|
|
local opt = vim.opt
|
2024-03-09 12:43:19 +00:00
|
|
|
local o = vim.o
|
2024-02-29 16:33:20 +00:00
|
|
|
local g = vim.g
|
|
|
|
|
|
|
|
-------------------------------------- globals -----------------------------------------
|
|
|
|
g.toggle_theme_icon = " "
|
|
|
|
|
|
|
|
-------------------------------------- options ------------------------------------------
|
2024-03-09 12:43:19 +00:00
|
|
|
o.laststatus = 3
|
|
|
|
o.showmode = false
|
2024-02-29 16:33:20 +00:00
|
|
|
|
2024-03-09 12:43:19 +00:00
|
|
|
o.clipboard = "unnamedplus"
|
|
|
|
o.cursorline = true
|
|
|
|
o.cursorlineopt = "number"
|
2024-02-29 16:33:20 +00:00
|
|
|
|
|
|
|
-- Indenting
|
2024-03-09 12:43:19 +00:00
|
|
|
o.expandtab = true
|
|
|
|
o.shiftwidth = 2
|
|
|
|
o.smartindent = true
|
|
|
|
o.tabstop = 2
|
|
|
|
o.softtabstop = 2
|
2024-02-29 16:33:20 +00:00
|
|
|
|
|
|
|
opt.fillchars = { eob = " " }
|
2024-03-09 12:43:19 +00:00
|
|
|
o.ignorecase = true
|
|
|
|
o.smartcase = true
|
|
|
|
o.mouse = "a"
|
2024-02-29 16:33:20 +00:00
|
|
|
|
|
|
|
-- Numbers
|
2024-03-09 12:43:19 +00:00
|
|
|
o.number = true
|
|
|
|
o.numberwidth = 2
|
|
|
|
o.ruler = false
|
2024-02-29 16:33:20 +00:00
|
|
|
|
|
|
|
-- disable nvim intro
|
|
|
|
opt.shortmess:append "sI"
|
|
|
|
|
2024-03-09 12:43:19 +00:00
|
|
|
o.signcolumn = "yes"
|
|
|
|
o.splitbelow = true
|
|
|
|
o.splitright = true
|
|
|
|
o.timeoutlen = 400
|
|
|
|
o.undofile = true
|
2024-02-29 16:33:20 +00:00
|
|
|
|
|
|
|
-- interval for writing swap file to disk, also used by gitsigns
|
2024-03-09 12:43:19 +00:00
|
|
|
o.updatetime = 250
|
2024-02-29 16:33:20 +00:00
|
|
|
|
|
|
|
-- go to previous/next line with h,l,left arrow and right arrow
|
|
|
|
-- when cursor reaches end/beginning of line
|
|
|
|
opt.whichwrap:append "<>[]hl"
|
|
|
|
|
2024-03-04 02:37:10 +00:00
|
|
|
-- g.mapleader = " "
|
2024-02-29 16:33:20 +00:00
|
|
|
|
|
|
|
-- disable some default providers
|
|
|
|
vim.g["loaded_node_provider"] = 0
|
|
|
|
vim.g["loaded_python3_provider"] = 0
|
|
|
|
vim.g["loaded_perl_provider"] = 0
|
|
|
|
vim.g["loaded_ruby_provider"] = 0
|
|
|
|
|
|
|
|
-- add binaries installed by mason.nvim to path
|
|
|
|
local is_windows = vim.loop.os_uname().sysname == "Windows_NT"
|
|
|
|
vim.env.PATH = vim.fn.stdpath "data" .. "/mason/bin" .. (is_windows and ";" or ":") .. vim.env.PATH
|