-
Notifications
You must be signed in to change notification settings - Fork 129
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: Nushell Extra Theme Config #298
Conversation
81ff22a
to
4a99577
Compare
This looks great and is something that should be added to the extra section. |
4a99577
to
5939a63
Compare
@EdenEast, great. Happy to contribute. I think it is in a rievewable state now. |
lua/nightfox/extra/nushell.lua
Outdated
|
||
function M.generate(spec) | ||
local content = [[ | ||
let nightfox_theme = { |
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.
The name can be taken from the palette with spec.palette.meta.name
I would use this to change the table name so that you know what actual theme it is.
let nightfox_theme = { | |
let ${palette.meta.name}_theme = { |
lua/nightfox/extra/nushell.lua
Outdated
binary: "${syntax.number}" | ||
block: "${syntax.bracket}" | ||
bool: "${syntax.const}" | ||
cellpath: "${palette.white}" |
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.
I would be careful with setting either while or black by themselves. The issue is that for light themes like dayfox these colors will be very subtle. I would suggest that you append to the spec
table with the following:
local P = spec.palette
spec.harsh = P.meta.light and P.black or P.white
spec.subtle = P.meta.light and P.white or P.black
This would then allow you to call cellpath: ${harsh}
. This would be correct for both dark and light themes.
5939a63
to
ed72c5f
Compare
This looks good. If you could just resolve the stylua errors and we are good to get this merged. |
This commit adds extra files to generate a theming file for Nushell (see https://www.nushell.sh/book/coloring_and_theming.html#theming). The file can be source as in following example: ```nushell source /path/to/nightfox.nvim/extra/nightfox/nightfox_nushell.nu let-env config = ($env.config | upsert color_config $nightfox_theme) ```
ed72c5f
to
3d8cd3b
Compare
@EdenEast, I think the stylua errors are fixed now. Thanks for helping me getting this done and thanks for accepting my contribution, |
All green LGTM! |
This commit adds extra files to generate a theming file for Nushell (see https://www.nushell.sh/book/coloring_and_theming.html#theming). The file can be source as in following example:
The following GIF shows the difference between the default theme (the first
let
andecho
example) and the modified theme (secondlet
andecho
example).I need to figure out the remaining colors. I want to get early feedback if that is something you want to include.