Skip to content
This repository has been archived by the owner on Apr 17, 2021. It is now read-only.

Commit

Permalink
Fix windows help messages sended to non windows users
Browse files Browse the repository at this point in the history
  • Loading branch information
nuriofernandez committed Mar 27, 2020
1 parent c643147 commit 650f654
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,23 +51,22 @@ func PrintHelp() {
fmt.Println("WinSCP stored password finder")

// WinSCP's password manual decryption mode.
fmt.Println("Registry:")
fmt.Println(" Open regedit and navigate to [HKEY_CURRENT_USER\\Software\\Martin Prikryl\\WinSCP 2\\Sessions] to get the hostname, username and encrypted password")
if runtime.GOOS == "windows" {
fmt.Println("Registry:")
fmt.Println(" Open regedit and navigate to [HKEY_CURRENT_USER\\Software\\Martin Prikryl\\WinSCP 2\\Sessions] to get the hostname, username and encrypted password")
fmt.Println(" Usage winscppasswd.exe <host> <username> <encrypted_password>")
} else {
fmt.Println(" Usage ./winscppasswd <host> <username> <encrypted_password>")
}

// WinSCP's ini file mode.
fmt.Println("\n\nWinSCP.ini:")
fmt.Println("\nWinSCP.ini:")
if runtime.GOOS == "windows" {
fmt.Println(" Usage winscppasswd.exe ini [<filepath>]")
fmt.Printf(" Default value <filepath>: %s\n", GetDefaultWinSCPIniFilePath())
} else {
fmt.Println(" Usage ./winscppasswd ini [<filepath>]")
}
fmt.Printf(" Default value <filepath>: %s\n", GetDefaultWinSCPIniFilePath())
return
}

// GetDefaultWinSCPIniFilePath obtains default WinSCP configuration file.
Expand Down

0 comments on commit 650f654

Please sign in to comment.