-
Notifications
You must be signed in to change notification settings - Fork 4.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow ssh and sshconfig tags for ssh config syntax highlighting. #7041
Comments
We'd certainly accept a PR if you've got the time 😉 |
I'm not familiar with how the repo is laid out, but a brief search for linguist/lib/linguist/languages.yml Lines 6522 to 6534 in f0aebbe
According to that, I would think Perhaps the previous test was rendered years ago, made inactive, and never re-rendered. I'll try again now:
Host my-nickname
Hostname my-nickname.example.com
User me
|
@lildude Can you direct me as to what I should be looking for? The thing that seemed the obvious thing either isn't applied to the deployed GitHub editor at large, or is a red herring. |
If you're wanting to use the various other forms, you should add an |
Describe the enhancement
Support
```sshconfig
,```ssh
, and```ssh-config
tags for sshconfig highlight blocks.Support in the Wild
At the time of the previous issue discussion ssh config (#3450), the
Include
directive for ssh config was not well known, nor widely adopted.However, now it is supported in macOS, Ubuntu, and many other Linuxes (anything with OpenSSH 8.x or higher): https://man.openbsd.org/ssh_config.5
Although the
Include
directive does not specify which extension should be used,.ssh
and.sshconfig
seem to be the common extensions, when one is used.vim
also names its syntax highlightingsshconfig
.Specifically,
.ssh-config
is NOT a common extention andssh-config
is not a common name for the syntax - at least not as far as I can tell.As can be seen in #3450 (comment), currently only
```ssh-config
is supported by GitHub.Recommendations
I'm recommending that
sshconfig
, in particular, be added for syntax highlighting as it seems to be the de facto naming convention.I'd also recommend
ssh
because it's the most intuitive - and I highly, highly doubt that there will be some sort of OpenSSH DSL script that would need thessh
tag in the future. That said, I do understand that, categorically,ssh
might feel wrong as it would seem to describe an ssh DSL rather than a config format. However, since the layperson would reasonably assume thatssh
is the syntax and probably isn't aware thatsshconfig
is the de facto name for the syntax.On another note, I would argue against
ssh_config
as the tag as that seems to defy the tag convention, and refers specifically to the file naming convention used for substituting the/
in~/.ssh/config
and the suggested system-wide configuration file name/etc/ssh/ssh_config
, not the syntax itself.The text was updated successfully, but these errors were encountered: