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
broot: use upstream defaults, allow all config options #2644
Conversation
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 the contribution!
73953da
to
8524f50
Compare
Thank you for your contribution! I marked this pull request as stale due to inactivity. Please read the relevant sections below before commenting. If you are the original author of the PR
If you are not the original author of the PR
|
Oh, about IFD. I have nothing against it and use it all the time. The main concern would be performance and clarity. So in HM I would avoid using it in excess and with slow to build derivations. I would also avoid using them when a non-IFD solution exists of comparable code clarity. So in this particular case I think we could try avoiding it by letting Bash source the generated file since it would be equally clear (arguably even more so). |
Thanks for your guidance! This could also help future decisions. With this said, I think this PR is ready. |
Co-authored-by: Nicolas Berbiche <nic.berbiche@gmail.com>
Thank you for your contribution! I marked this pull request as stale due to inactivity. Please read the relevant sections below before commenting. If you are the original author of the PR
If you are not the original author of the PR
|
I'm merging this on my own to avoid bothering others. All expressed concerns have been addressed and a decision about IFD was made. |
Yep, good work! Btw, does the test build for you? I seem to get an error
|
The latest broot update moved the configuration file to $src/resources/default-conf/conf.hjson |
Sorry, I should have run the tests again given the age of this PR. Thankfully #3273 fixes this. |
…#2644) * broot: use freeformType for config * broot: use defaults from upstream closes nix-community#2395 * broot: generate shell function * broot: add @dermetfan to CODEOWNERS * broot: rename `config` option to `settings` * broot: make example more idiomatic Co-authored-by: Nicolas Berbiche <nic.berbiche@gmail.com> Co-authored-by: Nicolas Berbiche <nic.berbiche@gmail.com>
…#2644) * broot: use freeformType for config * broot: use defaults from upstream closes nix-community#2395 * broot: generate shell function * broot: add @dermetfan to CODEOWNERS * broot: rename `config` option to `settings` * broot: make example more idiomatic Co-authored-by: Nicolas Berbiche <nic.berbiche@gmail.com> Co-authored-by: Nicolas Berbiche <nic.berbiche@gmail.com>
Description
The module did not allow to set all possible config options. It is now a freeform module in addition to the typed options that were already declared.
Default verbs were hard-coded and out of date (closes #2395) and therefore a maintenance burden. The default config from upstream is now used. Unfortunately this requires IFD.
I also changed the shell functions to be generated using IFD while I was at it so they won't have to be manually updated in the future. I do realize this may not be desired because they probably do not change often. I am fully happy removing that commit if anyone wishes.
Checklist
Change is backwards compatible.
Partly: The Nix options interface is, but the resulting config file will be based on upstream's defaults now.
Code formatted with
./format
.Code tested through
nix-shell --pure tests -A run.all
.Test cases updated/added. See example.
Commit messages are formatted like
See CONTRIBUTING for more information and recent commit messages for examples.
If this PR adds a new moduleIt does not, but the original author is not using broot anymore.Added myself as module maintainer. See example.
Added myself and the module files to
.github/CODEOWNERS
.