Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // Log allows customers to hook their own logging function into the library // to receive logs. By default, discarded. // Logs are only emitted for invisible events and handled errors. // Errors returned to the library user will not be logged and should be handled by the caller. Log = func(level int, format string, args ...interface{}) {} )
Functions ¶
func UserConfigPath ¶
UserConfigPath returns the folder holding the user SSH configuration files. Usually $HOME/.ssh
Types ¶
type Override ¶
type Override func(*ssh.ClientConfig)
type Pattern ¶
type Pattern struct {
// contains filtered or unexported fields
}
func NewPattern ¶
func (*Pattern) RawMatches ¶
type PatternList ¶
type PatternList []*Pattern
func NewPatternList ¶
func NewPatternList(s string) (PatternList, error)
func (PatternList) Match ¶
func (pl PatternList) Match(text string) bool
type SSHClientConfig ¶
type SSHClientConfig struct { // Configuration paths to lookup for configuration. LookupPaths []string }
func NewSSHClientConfig ¶
func NewSSHClientConfig(path string) *SSHClientConfig
For each parameter, the first obtained value will be used.
func (SSHClientConfig) DialAddr ¶
func (c SSHClientConfig) DialAddr(addr string) string
func (SSHClientConfig) HostName ¶
func (c SSHClientConfig) HostName(host string) string
func (SSHClientConfig) Port ¶
func (c SSHClientConfig) Port(host, port string) string
func (SSHClientConfig) SSHClientConfig ¶
func (c SSHClientConfig) SSHClientConfig(host string, overrides ...Override) (*ssh.ClientConfig, error)
Click to show internal directories.
Click to hide internal directories.