nikolassv / bartib

A simple timetracker for the command line. It saves a log of all tracked activities as a plaintext file and allows you to create flexible reports.
GNU General Public License v3.0
636 stars 34 forks source link

Add tab completion for fish #22

Closed NijeboerFrank closed 1 year ago

NijeboerFrank commented 1 year ago

Hi, thanks for this great application! I'm using the fish shell and I wanted tab completion for longer project names in Bartib. So I dove into a little rabbit hole for fish completion and I ended up implementing a bit more than I originally set out to do.

In the end, I created completions for all the commands, as well as completions for project names and task descriptions. It's required that you have set the BARTIB_FILE variable in your shell for the project and description completions to work though. I think it should work well, but I have not fully tested all the edge cases. Just wanted to share this so others could use it too and explore bartib a bit easier if they use fish :smile: