32 lines
777 B
Lua
32 lines
777 B
Lua
vim.wo.number = true
|
|
vim.o.relativenumber = true
|
|
vim.o.clipboard = "unnamedplus"
|
|
vim.o.wrap = false
|
|
vim.o.linebreak = true
|
|
vim.o.mouse = "a"
|
|
vim.o.autoindent = true
|
|
vim.o.ignorecase = true
|
|
vim.o.smartcase = true
|
|
vim.o.shiftwidth = 2
|
|
vim.o.tabstop = 2
|
|
vim.o.softtabstop = 2
|
|
vim.o.expandtab = true
|
|
vim.o.cursorline = true
|
|
vim.o.smartindent = true
|
|
vim.o.showtabline = 2
|
|
vim.o.conceallevel = 0
|
|
vim.o.undofile = true
|
|
-- vim.o.colorcolumn = 120
|
|
|
|
-- Make neovim remember the last location the file was opened in
|
|
vim.api.nvim_create_autocmd("BufReadPost", {
|
|
callback = function()
|
|
local mark = vim.api.nvim_buf_get_mark(0, '"')
|
|
local lcount = vim.api.nvim_buf_line_count(0)
|
|
|
|
if mark[1] > 0 and mark[1] <= lcount then
|
|
pcall(vim.api.nvim_win_set_cursor, 0, mark)
|
|
end
|
|
end,
|
|
})
|