lvim-tech/lvim

Is this a bug in core.funcs.options_set?

mag1c1an1 opened this issue · 1 comments

M.options_set = function(options)
    for k, v in pairs(options) do
        if v == true or v == false then
            vim.cmd("set " .. k)
        else
            vim.cmd("set " .. k .. "=" .. v)
        end
    end
end

Let's say I want to change the relative number option by the config interface you post to us. I write relativenumber = false in config.global.lvim . But it doesn't work due to the above function.
Sorry I'm not a English native speaker. But I hope you can understand what I am saying.

Fixed - number and relativenumber moved to global_opt.
But I use lvim-focus and you can rewrite setup:

-- lua/modules/global/configs/ui/init.lua
function config.lvim_focus()
    require("lvim-focus").setup({
        relativenumber = false
    })
end

Or remove plugin.