git (terminal, SourceTree) has to enter a password every time you clone/pull/push. It's really frustrating. Let's take a look at how to store the password.
Method 1. Set a password to remember (default 15 minutes)
git config --global credential.helper cache
Method 2: Set the time yourself (set 15 minutes here---60*15=900s)
git config credential.helper 'cache --timeout=900'
Method 3. Long-term storage of passwords
git config --global credential.helper store
View the git configuration file after setting up
git config --lis
Found one more red box content
Question: If after completing the above settings, push still prompts that passphrase for key '/Users/baidu/.ssh/id_rsa' requires a password.
Solution: There will be a multi-step prompt after the terminal command ssh-keygen -p . When prompted Enter old passphrase:, enter the computer password. For other prompts, just enter the enter key.
The setup is now complete! Please give me some advice.