-
-
Notifications
You must be signed in to change notification settings - Fork 681
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
feat: support themes
directory
#1577
Conversation
@a-kenji Hi! I plan to merge this PR if there are no problems. |
@jaeheonji, |
@a-kenji Thank you!
When I try to add new |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for implementing this, it is pretty awesome!
There are a few things that can get addressed:
I think the serialization should be done in the setup step itself, that way the themes specified in the config
and the themes
directory can get merged. And people can have some themes in their config and some in the directory. This will also take some logic outside of the client, and make it possibly less error prone.
What do you think about allowing the name of the theme in the theme itself? That way it would be more portable and you could copy your theme from a theme directory into the configuration file.
In the same vein, could it make sense to allow specifying related themes inside the same file?
For example molokai.yaml
having a molokai-dark
and a molokai-light
.
Also it would be great, if you could add the theme directory to zellij setup --check
!
What do you think?
Ah, yes that makes sense. |
You're right. I initially thought of two ways. The first, as you mentioned, is to merge themes by loading individual files during the setup process. The second is to look up themes in the config first, and load the file if there is no theme in the config. Both are good methods, but I did not choose the first method because it seems that there will be more File I/O than the second method. (Of course, it usually won't affect performance that much.) However, if it is an example like
I agree 100% 👍
Cool! It will be helpful. Thank you so much for the feedback and finding the missing parts. It will take some time to fix 😅 |
@a-kenji I updated it. please check it out when you have time 😄 |
This is very awesome, and it works now as I expect it! Thanks for the great work. |
Resolve #1491
EDIT: The
theme_dir
option was removed due to another issue. Therefore,themes
directory always exists under the zellij config directory.