package
Version:
v0.1.0
Opens a new window with list of versions in this module.
Published: Aug 20, 2026
License: MIT
Opens a new window with license information.
Imports: 4
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
¶
Package sshconfig 从 OpenSSH 配置中列出 Host 别名(Spec §4.1)。
func DefaultConfigPath() string
DefaultConfigPath 返回用户默认 ssh config 路径。
ListHosts 解析主 config 中的 Host 行;排除含 * 或 ? 的模式。
S2 最低要求:主文件 Host 行;Include 递归为 should(此处做一层 Include 尽力解析)。
HostEntry 表示一个非通配 Host 别名及其寻址字段(不探测网络)。
ListHostEntries 解析 config,返回每个非通配 Host 别名的寻址字段。
Source Files
¶
Click to show internal directories.
Click to hide internal directories.