scrolloff needs to be set before scrolleof initialises

This commit is contained in:
2026-05-06 13:53:08 +01:00
parent 188b15d360
commit 1b887d67bc
2 changed files with 17 additions and 17 deletions

View File

@@ -1,6 +1,10 @@
vim.g.mapleader = " "
vim.g.maplocalleader = ","
-- Scrolloff
local scrolloff = math.floor(vim.o.lines / 2) - 3
vim.opt.scrolloff = scrolloff
require("plugins.init")
require("config.autocmd")
require("config.binds")
@@ -39,10 +43,6 @@ vim.opt.incsearch = true
-- Nowrap
vim.opt.wrap = false
-- Scrolloff
local scrolloff = math.floor(vim.o.lines / 2) - 3
vim.opt.scrolloff = scrolloff
-- Indent
vim.o.autoindent = true