From 7ff5ca4a6a9d59ca2e57e8c01d85b9daf15746a8 Mon Sep 17 00:00:00 2001 From: "Kenneth Benzie (Benie)" Date: Tue, 29 Jul 2025 11:38:46 +0100 Subject: [PATCH] Add support for local overrides in lua/local.lua GUI's like Neovide require system specific settings for font size based on monitor resolution, pixel density, and scaling. Add support for loading `lua/local.lua` if it exists to enable overriding the default for `vim.o.guifont` or similar options. --- .gitignore | 1 + init.lua | 3 +++ 2 files changed, 4 insertions(+) diff --git a/.gitignore b/.gitignore index 57a4847..3daaadc 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ lazy-lock.json spell/*.spl +lua/local.lua diff --git a/init.lua b/init.lua index 769625e..fb4658d 100644 --- a/init.lua +++ b/init.lua @@ -6,6 +6,9 @@ if vim.g.neovide then vim.g.neovide_cursor_animation_length = 0 end +-- load config from lua/local.lua if present +pcall(function() require('local') end) + local lazypath = vim.fn.stdpath('data') .. '/lazy/lazy.nvim' if not vim.loop.fs_stat(lazypath) then vim.fn.system({ 'git', 'clone', '--filter=blob:none',