-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Create color slots for day and night #8
Comments
Hello, thank you for the suggestion! |
Based on your suggestion and from what I've read about the plugin, does something like this sound right to you? local last_color = require('last-color')
return {
"f-person/auto-dark-mode.nvim",
config = {
set_dark_mode = function()
-- last-color will now write to `<cache_dir>/last-color.dark` for any subsequent `colorscheme` commands
last_color.context('dark')
-- last-color will now read from `<cache_dir>/last-color.dark`
vim.cmd.colorscheme(last_color.recall())
end,
set_light_mode = function()
-- last-color will now write to `<cache_dir>/last-color.light` for any subsequent `colorscheme` commands
last_color.context('light')
-- last-color will now read from `<cache_dir>/last-color.light`
vim.cmd.colorscheme(last_color.recall())
end,
},
} So effectively the user is able to call |
Yes I think that'd be a nice interface for it! |
Can you confirm #9 works as you would like? The syntax has changed slightly from my original post: return {
'f-person/auto-dark-mode.nvim',
config = {
set_dark_mode = function()
local last_color = require('last-color')
last_color.slot('dark')
vim.cmd.colorscheme(last_color.recall())
end,
set_light_mode = function()
local last_color = require('last-color')
last_color.slot('light')
vim.cmd.colorscheme(last_color.recall())
end,
},
} |
Just seeing that now! Will get back to you shortly when I tried it. |
I use
f-person/auto-dark-mode.nvim
plugin to automatically infer from the system's colorscheme.I'd appreciate if
raddari/last-color
could remember two colorschemes separately in customisable slots.The text was updated successfully, but these errors were encountered: