From 34bcbd5489112e649f566cb5784a671f7bbcd51e Mon Sep 17 00:00:00 2001 From: LostNeophyte Date: Tue, 10 Jan 2023 09:11:40 +0100 Subject: feat: deprecation warning --- lua/lvim/config/_deprecated.lua | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'lua/lvim/config') diff --git a/lua/lvim/config/_deprecated.lua b/lua/lvim/config/_deprecated.lua index 4cf4381e..594b47af 100644 --- a/lua/lvim/config/_deprecated.lua +++ b/lua/lvim/config/_deprecated.lua @@ -79,6 +79,22 @@ function M.handle() ---@deprecated lvim.lang = {} setmetatable(lvim.lang, mt) + + ---@deprecated + lvim.builtin.theme.tokyonight = {} + local tokyonight_deprecation = function(t, k, v) + lvim.colorscheme = "lunar" + deprecate( + "lvim.builtin.theme.tokyonight." .. k, + "tokyonight was removed from core plugins, configure it like this " + ) + rawset(t, k, v ~= nil and v or {}) + return t[k] + end + setmetatable(lvim.builtin.theme.tokyonight, { + __newindex = tokyonight_deprecation, + __index = tokyonight_deprecation, + }) end return M -- cgit v1.2.3