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

generate/gen/completions command: Generate shell completions #44

Open
simonsan opened this issue Jan 23, 2024 · 1 comment
Open

generate/gen/completions command: Generate shell completions #44

simonsan opened this issue Jan 23, 2024 · 1 comment
Labels
enhancement New feature or request

Comments

@simonsan
Copy link
Contributor

I see that you are using clap for the CLI, there is https://crates.io/crates/clap_complete to automatically generate shell completions. It would be nice, to be able to generate completions for different shells by just calling bartib completions >> {my_shell_profile}. Here is a possible implementation: https://github.com/rustic-rs/rustic/blob/main/src/commands/completions.rs

Depending on if you want to further generate other files (e.g a bartib.toml for configuration of e.g. style of reports, default timezones etc.) it would be useful to have that under bartib gen completions (in the future maybe there could be a bartib gen configor just the top-level bartib completions.

@nikolassv
Copy link
Owner

Thank you for bringing this crate to my attention. I didn't know it existed. This looks like something bartib should definitely have.

@nikolassv nikolassv added the enhancement New feature or request label Jan 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants