refactor: derive enum values from man page instead of hardcoding
Problem: static_enums was a manually maintained table of ~40 keywords
that could go stale when OpenSSH adds or changes config options.
Solution: parse enum values directly from the ssh_config man page using
two strategies: definitive list sentences ("The argument must be X, Y,
or Z") and fallback extraction from "set to X" patterns. Also fixes
keyword detection to handle digits (ForwardX11) and inline definitions
(Tunnel, SetEnv). Covers 36/41 old keywords plus discovers 4 new ones
(IPQoS, SyslogFacility, ObscureKeystrokeTiming, ControlPersist).
This commit is contained in:
parent
679a4bf804
commit
e9bb8de70f
2 changed files with 139 additions and 61 deletions
|
|
@ -12,7 +12,11 @@ local MAN_PAGE = table.concat({
|
|||
' StrictHostKeyChecking',
|
||||
' If this flag is set to yes, ssh(1) will never automatically add',
|
||||
' host keys to the ~/.ssh/known_hosts file, and refuses to connect',
|
||||
' to hosts whose host key has changed.',
|
||||
' to hosts whose host key has changed. If this flag is set to',
|
||||
' accept-new then ssh will automatically add new host keys. If',
|
||||
' this flag is set to no or off, ssh will automatically add new',
|
||||
' host keys. If this flag is set to ask (the default), new host',
|
||||
' keys will be added only after the user has confirmed.',
|
||||
'',
|
||||
' Hostname',
|
||||
' Specifies the real host name to log into.',
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue