The idea behind have an SSH passphrase is security and I’m all for that. When it comes to working on a large project where you’re pulling updates from a repository and running composer update to make sure all of the associated packages are updated, it gets a little tedious, though.

Assuming you’re comfortable with wanting to enter your SSH phrase once (so you’re not having to do it for every single dependency you’re installing), it’s really easy to store the passphrase.

Enter Your SSH Passphrase Once

So if you’re working in a repository that maintains a lot of dependencies and you find yourself needing to enter your passphrase for each repository, here’s how to configure your ssh-agent so you only need ot enter your SSH passphrase once.

In the root directory of the repository, enter the following command:

Next, you’ll be asked to enter the passphrase associated with your id_rsa file (assuming that it’s kept in the .ssh directory). And after entering it, you’ll be given the following message:

After this, you shouldn’t be prompted to enter your passphrase anymore.