add: pwsh :Invoke-SshAdd
This commit is contained in:
parent
d5103f0367
commit
2657b96fad
1 changed files with 13 additions and 0 deletions
|
@ -126,6 +126,19 @@ function Enable-SshAgent {
|
|||
#>
|
||||
sudo Set-Service -Name ssh-agent -StartupType Manual && Start-Service ssh-agent
|
||||
}
|
||||
# auto start ssh-agent and do ssh-add
|
||||
function Invoke-SshAdd {
|
||||
<#
|
||||
.SYNOPSIS
|
||||
Starts ssh-agent and do ssh-add
|
||||
|
||||
.DESCRIPTION
|
||||
Starts ssh-agent as admin and do ssh-add, to add sshkeys to ssh-agent.
|
||||
#>
|
||||
|
||||
Enable-SshAgent
|
||||
ssh-add
|
||||
}
|
||||
# execute "ssh-add" to add keys
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue