fix: make EZA_COLORS=reset clear built-in styles#1718
fix: make EZA_COLORS=reset clear built-in styles#1718martenlienen wants to merge 1 commit intoeza-community:mainfrom
Conversation
96f5d96 to
2593d0c
Compare
|
Thank you for working on this! I'm looking forward to this being merged. I compiled this branch to try it out. I set When I created a blank theme file with Could this PR be extended to make |
|
I think mixing |
Agreed that Since Thank you again for working on this! |
|
That precedence problem is also a separate issue from this one I believe. I deliberately do not use the theme file, because I do not want eza to have to read a file from disk every time I use it. |
namurphy
left a comment
There was a problem hiding this comment.
Since there will still be the separate issue that setting EZA_COLORS=reset will not do anything when a theme.yml is in use, adding this caveat to the documentation would likely help prevent confusion by users who have a theme.yml and want to do this reset.
Since #1724 proposes adding a configuration variable within theme.yml to perform this reset, I'll add a note there to update the documentation near the discussion about EZA_COLORS=reset.
Thank you again for submitting this!
| So setting `EZA_COLORS="reset:*.txt=31"` will highlight only text | ||
| files; setting `EZA_COLORS="reset"` will highlight nothing. | ||
| You can also disable eza's built\-in mappings entirely by including a `reset` entry at the beginning of `EZA_COLORS`. | ||
| So setting `EZA_COLORS="reset:*.txt=31"` will highlight only text files in addition to any styles in `LS_COLORS`; setting `EZA_COLORS="reset"` disables eza's built\-ins completely. |
There was a problem hiding this comment.
| So setting `EZA_COLORS="reset:*.txt=31"` will highlight only text files in addition to any styles in `LS_COLORS`; setting `EZA_COLORS="reset"` disables eza's built\-ins completely. | |
| So setting `EZA_COLORS="reset:*.txt=31"` will highlight only text files in addition to any styles in `LS_COLORS`; setting `EZA_COLORS="reset"` disables eza's built\-ins completely. | |
| However, setting `EZA_COLORS="reset"` is not yet supported when a configuration file (`theme.yml`) is in use. |
| You can also disable this built-in set entirely by including a `reset` entry at the beginning of `EZA_COLORS`. | ||
| So setting `EZA_COLORS="reset:*.txt=31"` will highlight only text files; setting `EZA_COLORS="reset"` will highlight nothing. | ||
| You can also disable eza's built-in mapping entirely by including a `reset` entry at the beginning of `EZA_COLORS`. | ||
| So setting `EZA_COLORS="reset:*.txt=31"` will highlight only text files in addition to any styles in `LS_COLORS`; setting `EZA_COLORS="reset"` disables eza's built-ins completely. |
There was a problem hiding this comment.
| So setting `EZA_COLORS="reset:*.txt=31"` will highlight only text files in addition to any styles in `LS_COLORS`; setting `EZA_COLORS="reset"` disables eza's built-ins completely. | |
| So setting `EZA_COLORS="reset:*.txt=31"` will highlight only text files in addition to any styles in `LS_COLORS`; setting `EZA_COLORS="reset"` disables eza's built-ins completely. | |
| However, setting `EZA_COLORS="reset"` is not yet supported when a configuration file (`theme.yml`) is in use. |
Description
This PR fixes
EZA_COLORS=resetto actually do what the documentation says, i.e. reset eza's styles to plain and disabling the default theme. At the moment, resetting the colors has no effect.How Has This Been Tested?
I have added CLI tests to verify the correct coloring given
EZA_COLORS=resetandEZA_COLORS=reset:...and the interaction withLS_COLORS.Fixes #731.