Skip to content

Commit

Permalink
style: change ssh variable name
Browse files Browse the repository at this point in the history
  • Loading branch information
d-strobel committed Nov 16, 2023
1 parent f085555 commit 285f72e
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions connection/ssh.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ type SSHConfig struct {

const (
// SSH default values
defaultSSHPort int = 22
defaultKnownHostPath string = ".ssh/known_hosts"
defaultSSHPort int = 22
defaultKnownHostsPath string = ".ssh/known_hosts"
)

func newSSHClient(config *SSHConfig) (*ssh.Client, error) {
Expand Down Expand Up @@ -136,7 +136,7 @@ func knownHostCallback(config *SSHConfig) (ssh.HostKeyCallback, error) {
}

// Set default values
knownHostsPath := fmt.Sprintf("%s/%s", user.HomeDir, defaultKnownHostPath)
knownHostsPath := fmt.Sprintf("%s/%s", user.HomeDir, defaultKnownHostsPath)
if config.SSHKnownHostsPath != "" {
knownHostsPath = config.SSHKnownHostsPath
}
Expand Down

0 comments on commit 285f72e

Please sign in to comment.