k9s icon indicating copy to clipboard operation
k9s copied to clipboard

Add Shift+D command to delete numeric namespace bindings

Open placintaalexandru opened this issue 2 years ago • 9 comments

Addresses #2104

placintaalexandru avatar Nov 05 '23 21:11 placintaalexandru

@placintaalexandru Thank you for this update Alexandru!! I am kind of on the fence with this one... I think it might be best to enhance the ns view to offer a new col aka favorite and leverage a toggle to opt in/out to make up the favs ns list. That said, since auto favs ns is still in play, that list will keep changing and user would have to manually curate it. Which feels like a dud.

I agree @derailed . I can have a look at enhancing the fav ns thing: by default would be this behaviour that would allow you to delete the numeric bindings, but if the user specifies a flag (e.g., --fav) the fav ns will always be hardoced to the list specified by the user

If you agree, you can close this one and I'll work on what I said above if that is fine

placintaalexandru avatar Nov 08 '23 20:11 placintaalexandru

@placintaalexandru Thank you Alexandru!! I think we might be able to manage this without hopefully introducing a new flag?? Perhaps if the user sets her fav ns then the auto tracking ns could either be disabled is the fav ns list is full or just managed the list if there is still space in it??

derailed avatar Nov 10 '23 15:11 derailed

I mean, I could stil want a self managed list of 4 namespaces and those 4 to never change @derailed This is why I was thinking to a flag :\

placintaalexandru avatar Nov 10 '23 15:11 placintaalexandru

@placintaalexandru Thank you for this update Alexandru! I like this feature but it feels a bit heavy to me in its current shape?? Here is a thought. What if we displayed a favorite indicator (❤️) next to the namespace name and add an action something like f Toggle Favorite? Then users could leverage familiar constructs like multi-select, etc... to manage their fav list?

yeah, SGTM. I'll try to work on this one again

placintaalexandru avatar Nov 21 '23 20:11 placintaalexandru

hello @derailed There is now the possibility to toggle a namespace as favourite and, in case it exists, to toggle it out from favourite. I use behind data.Namespace.AddFavNS and data.Namespace.RmFavNS. image

I don't understand 2 things:

  1. Is it still required to limit the number of favourite namespaces to 9?
  2. How would the user manage the fav list? I did not understand the multi-select part

placintaalexandru avatar Dec 31 '23 11:12 placintaalexandru