-- Options are automatically loaded before lazy.nvim startup -- Default options that are always set: https://github.com/LazyVim/LazyVim/blob/main/lua/lazyvim/config/options.lua -- Add any additional options here -- Set to "basedpyright" to use basedpyright instead of pyright. vim.g.lazyvim_python_lsp = "basedpyright" -- Set to "ruff_lsp" to use the old LSP implementation version. vim.g.lazyvim_python_ruff = "ruff" -- then you need to set the option below. -- vim.g.lazyvim_picker = "telescope" vim.diagnostic.config({ float = { border = "rounded" }, }) local options = { backup = false, -- creates a backup file clipboard = { "unnamed", "unnamedplus" }, -- allows neovim to access the system clipboard completeopt = { "menuone", "noselect", "menu" }, -- mostly just for cmp conceallevel = 0, -- so that `` is visible in markdown files fileencoding = "utf-8", -- the encoding written to a file hlsearch = true, -- highlight all matches on previous search pattern ignorecase = true, -- ignore case in search patterns mouse = "a", -- allow the mouse to be used in neovim pumheight = 10, -- pop up menu height showmode = false, -- we don't need to see things like -- INSERT -- anymore showtabline = 0, -- always show tabs smartcase = true, -- smart case smartindent = true, -- make indenting smarter again splitbelow = true, -- force all horizontal splits to go below current window splitright = true, -- force all vertical splits to go to the right of current window swapfile = false, -- creates a swapfile termguicolors = true, -- set term gui colors (most terminals support this) timeoutlen = 1000, -- time to wait for a mapped sequence to complete (in milliseconds) undofile = true, -- enable persistent undo updatetime = 600, -- faster completion (4000ms default) writebackup = false, -- if a file is being edited by another program (or was written to file while editing with another program), it is not allowed to be edited expandtab = true, -- convert tabs to spaces shiftwidth = 2, -- the number of spaces inserted for each indentation tabstop = 2, -- insert 2 spaces for a tab softtabstop = 2, cursorline = true, -- highlight the current line number = true, -- set numbered lines laststatus = 3, relativenumber = true, numberwidth = 4, -- set number column width to 2 {default 4} signcolumn = "yes", -- always show the sign column, otherwise it would shift the text each time scrolloff = 8, -- is one of my fav sidescrolloff = 8, inccommand = "split", -- Show effect of search/replace command as it is being typed winblend = 30, -- windows transparency pumblend = 30, -- popup-menu transparency autoread = true, -- autoreads file if changed by other editor colorcolumn = "80,120", -- "88,120" cmdheight = 1, -- Give more space for displaying messages. linebreak = true, -- Prefer placing linebreaks breaking at whitespace showbreak = " ↪ ", -- Place arrow to indicate a linebreak wrap = true, -- Wrap text when line doesnt fit terminal width showcmd = true, -- Show command in bottom of screen hidden = true, errorbells = false, -- spell = true, -- Spell Check -- spelllang = { "en", "fr" }, -- Language to spell check -- use treesitter folding -- foldmethod = "expr", -- foldexpr = "nvim_treesitter#foldexpr()", } vim.opt.fillchars.eob = " " vim.opt.shortmess:append({ c = true }) vim.opt.whichwrap:append("<,>,[,],h,l") vim.opt.iskeyword:append("-") vim.opt.listchars.extends = "→" -- Insert arrows when text goes off screen vim.opt.listchars.precedes = "←" -- Same as previous vim.opt.formatoptions:append("j") -- Automatically delete comment characters when joining lines vim.opt.complete:append("k") vim.filetype.add({ extension = { conf = "conf", env = "dotenv", tiltfile = "tiltfile", Tiltfile = "tiltfile", }, filename = { [".env"] = "dotenv", ["tsconfig.json"] = "jsonc", [".yamlfmt"] = "yaml", }, pattern = { ["%.env%.[%w_.-]+"] = "dotenv", }, }) for k, v in pairs(options) do vim.opt[k] = v end