sshs icon indicating copy to clipboard operation
sshs copied to clipboard

Support for Include

Open jygastaud opened this issue 2 years ago • 4 comments

Thanks for your tool.

It would be really good it can support Include (eg Include conf.d/*) pattern from ~/.ssh/config.

jygastaud avatar Jun 13 '22 09:06 jygastaud

It's supposed to be already included, I'm using it locally. It doesn't work on your side?

quantumsheep avatar Jun 13 '22 09:06 quantumsheep

@quantumsheep Thanks for your quick answer. You're right, it almost works.

In fact, it was an include automatically added by platform.sh CLI that make the tool fails :/

That include looks like

Host *.platform.sh
  Include /Users/XXXX/.platformsh/ssh/*.config

jygastaud avatar Jun 13 '22 09:06 jygastaud

I didn't know Include directives could work inside Host directives. sshs is using sshconfig, I implemented it limiting usage inside of Host directives (https://github.com/mikkeloscar/sshconfig/blob/9ddb34f89ae36bf3ab5662bcd715458a9c93a16e/parser.go#L149).

I'll try to fix this this week :)

quantumsheep avatar Jun 13 '22 09:06 quantumsheep

Hello, I have the same usage and this error:

$ sshs
2022/06/15 09:08:14 include not allowed in Host block
$ cat ~/.ssh/config
Host *
  ForwardAgent yes

Include ~/.ssh/config.d/*.txt
$ sshs --version
sshs version 3.2.0
$ ssh -V
OpenSSH_8.2p1 Ubuntu-4ubuntu0.5, OpenSSL 1.1.1f  31 Mar 2020

Gounick avatar Jun 15 '22 07:06 Gounick

Hey! Include is now implemented in 4.0.0

quantumsheep avatar Feb 21 '24 21:02 quantumsheep