everettraven / buoy

A declarative Kubernetes dashboard in your terminal
https://everettraven.github.io/buoy/
Apache License 2.0
62 stars 1 forks source link

Add support for vim bindings #36

Open kranurag7 opened 1 year ago

kranurag7 commented 1 year ago

Thank you for the project. While navigating the tables, it would be really useful to add support for vim bindings.

This would require to map the following keys to:

j -> down
k -> up 
l -> right 
h -> left 

As of now, We use https://github.com/calyptia/go-bubble-table for rendering the table, and they only support arrows for navigation when moving in table view. I have the changes locally adding vim support to the upstream library, but I'm not sure if that's going to be accepted. If not, we can implement a table and keybindings from scratch.

everettraven commented 1 year ago

@kranurag7 thanks for writing up this issue! I totally agree that we should add vim keybindings. I'm not married to the use of calyptia/go-bubble-table because it does seem like a low maintenance project and was considering a couple options:

If you're willing to contribute any of this, let me know! I'm happy to accept any contributions that improve the overall feel and experience of the project!

everettraven commented 1 year ago

Another thought I had for a short term workaround could be to catch the vim keybindings in the table panel and remap that to an arrow key message to send to the go-bubble-table but that feels like unnecessary tech debt at this point and as much as I hacked this project together I'd like to start being a bit more picky about doing things the right way from the get go 😁