I want to do this command in one line:
git pull && [my passphrase]
How to do it?
This is not exactly what you asked for, but for http(s):
https://user:pass@domain/repo
but that's not really recommended as it would show your user/pass in a lot of places...Usage examples for credential helper
git config credential.helper store
- stores the credentials indefinitely.git config credential.helper 'cache --timeout=3600'
- stores for 60 minutesFor ssh-based access, you'd use ssh agent that will provide the ssh key when needed. This would require generating keys on your computer, storing the public key on the remote server and adding the private key to relevant keystore.