One solution is to add the command to the ~/.profile or ~/.bashrc . Then each time you open a new terminal, the command will be executed automatically. Since you are using zsh , you need to add the command to the ~/.zprofile or ~/.zshrc .
ssh-add -K ~/.ssh/id_rsa &> /dev/null
&> /dev/null should avoid viewing the Identity added message each time a new terminal window is opened.
source share