Skip to content
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

Doesn't load theme config files #3

Closed
IzzyDLP opened this issue Sep 2, 2023 · 3 comments
Closed

Doesn't load theme config files #3

IzzyDLP opened this issue Sep 2, 2023 · 3 comments

Comments

@IzzyDLP
Copy link

IzzyDLP commented Sep 2, 2023

I'm using the gruvbox theme and using themery gives an error of
Themery error: Could not open file or read: /home/name/.config/nvim/v:null

This is my current setup in themery.lua

require("themery").setup({
themes = {{
name = "Day",
colorscheme = "gruvbox",
before = [[vim.opt.background = "light"]],
themeConfigFile = "/home/name/.config/nvim/lua/blah/plugins/day.lua"
}, {
name = "Night",
colorscheme = "gruvbox",
before = [[vim.opt.background = "dark"]],
themeConfigFile = "/home/name/.config/nvim/lua/blah/plugins/night.lua"
}
}
})

@zaldih
Copy link
Owner

zaldih commented Sep 4, 2023

Thank you for opening this issue!
I will check it in a few days as soon as I have time :)

@zaldih
Copy link
Owner

zaldih commented Sep 4, 2023

Oh wait I think I've found the problem.

"themeConfigFile" should be declared once outside the themes tag.

Try this code:

require("themery").setup({
themeConfigFile = "/home/name/.config/nvim/lua/blah/plugins/sample-config.lua",
themes = {{
   name = "Day",
   colorscheme = "gruvbox",
   before = [[vim.opt.background = "light"]],
}, {
   name = "Night",
   colorscheme = "gruvbox",
   before = [[vim.opt.background = "dark"]],
}}
})

And in the sample-config.lua (or in your own configuration file) put this text:

-- Themery block
-- end themery block

@zaldih
Copy link
Owner

zaldih commented Sep 15, 2023

Closing due to inactivity.
If the problem is not solved by the proposed solution, please feel free to reopen the issue.

@zaldih zaldih closed this as completed Sep 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants