Skip to content

Instantly share code, notes, and snippets.

@sr2ds
Created November 27, 2018 12:07
Show Gist options
  • Select an option

  • Save sr2ds/b7e300b3ebe41236eeb493b84074a422 to your computer and use it in GitHub Desktop.

Select an option

Save sr2ds/b7e300b3ebe41236eeb493b84074a422 to your computer and use it in GitHub Desktop.
automatic ssh-add insert key
#!/usr/bin/expect
spawn ssh-add
set timeout -1
expect "passphrase"
send -- "YOU_KEY_PASS#\r"
expect eof
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment