quantumsheep / sshs

Terminal user interface for SSH
MIT License
822 stars 23 forks source link

FeatReq: Host/group folding #22

Open ghoffart opened 2 years ago

ghoffart commented 2 years ago

My .ssh/config has a lot of entries like

GroupNameA-ServerName1 GroupNameA-ServerName2 GroupNameA-ServerName3 GroupNameB-ServerName1 GroupNameB-ServerName2 GroupNameB-ServerName3

It’d be cool to have an option for sshs like --grouping where all similar named "GroupNameX" are in collapsable folders like:

GroupNameA--Servername1 ……………………………-Servername2 ……………………………-Servername3 GroupNameB+-[3 entries]

So GroupNameA is uncollapsed here, and GroupNameB collapsed, hiding another 3 entries prefixed with GroupNameB.

See also #21 - may has a weak dependency.

quantumsheep commented 2 years ago

I like this feature! --grouping could require a pattern like --grouping "%s-%s" so everyone can use their specific format. What do you think?

ghoffart commented 2 years ago

Even better, good suggestion and gives some more flexibility. I hope it doesn’t add too much complexity.

Ciriol commented 1 year ago

Could it be the same with a nested configuration : ~/.ssh/config.d/ |-GroupName-1 |-GroupName-2 Each files "GroupName-x" contain a list of hosts ?