Skip to content

Commit

Permalink
Start SSH agent even if no native agent is present
Browse files Browse the repository at this point in the history
  • Loading branch information
luigiberrettini committed Oct 29, 2018
1 parent 9e2cfe5 commit d52b707
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Win32-OpenSSH.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ function Get-NativeSshAgent {
# The ssh.exe binary version must include "OpenSSH"
# The windows ssh-agent service must exist
$service = Get-Service ssh-agent -ErrorAction Ignore
$executableMatches = Get-Command ssh.exe | ForEach-Object FileVersionInfo | Where-Object ProductVersion -match OpenSSH
$executableMatches = Get-Command ssh.exe -ErrorAction Ignore | ForEach-Object FileVersionInfo | Where-Object ProductVersion -match OpenSSH
$valid = $service -and $executableMatches
if ($valid) {
return $service;
Expand Down

0 comments on commit d52b707

Please sign in to comment.