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

Start removing colour config from explore #10270

Merged
merged 2 commits into from Sep 8, 2023

Conversation

rgwood
Copy link
Contributor

@rgwood rgwood commented Sep 8, 2023

This PR removes the explore.try.border_color config item, and instead always uses the separator colour (the one used for regular table borders) from the current theme.

The PR also removes some unused explore.config bits from the default config (I missed this in #10259).

Future Work

This PR is intentionally small, I want to confirm that I'm on the right track before I rip out more colour config from explore. If all goes well, expect more PRs like this soon.

Testing

I confirmed that this works by changing my separator colour in config.nu, and also confirmed that nothing breaks if a user still has explore.try.border_color in their config.

Copy link
Collaborator

@fdncred fdncred left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this is right. The only thing I was thinking about was whether accessing the colors via the StyleComputer is right. I was originally thinking that we'd just pull from the config, but after looking at more code, StyleComputer does that already, of course, so I think we're good to go here.

@rgwood rgwood merged commit e62a77a into nushell:main Sep 8, 2023
19 checks passed
@rgwood
Copy link
Contributor Author

rgwood commented Sep 8, 2023

Thanks for the quick review!

rgwood added a commit that referenced this pull request Oct 1, 2023
Remove code for 2 no-longer-used configuration options in `explore`:
`explore.config.cursor_color` and `explore.config.border_color`.

Think I made these unnecessary in
#10533 and
#10270 but missed this code, my
bad. The `explore` config code is a little hard to follow because it
does so many key lookups in hashmaps.
hardfau1t pushed a commit to hardfau1t/nushell that referenced this pull request Dec 14, 2023
Remove code for 2 no-longer-used configuration options in `explore`:
`explore.config.cursor_color` and `explore.config.border_color`.

Think I made these unnecessary in
nushell#10533 and
nushell#10270 but missed this code, my
bad. The `explore` config code is a little hard to follow because it
does so many key lookups in hashmaps.
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

Successfully merging this pull request may close these issues.

None yet

2 participants