I removed my .gitconfig by accident. I added new identies by
git add [file]
git remote ... [identity addition]
I am surprised when Git did not make a .gitconfig file which contain my secret tokens to my Home.
Git must have put the secret tokens elsewhere. However, I have not been able to find the location.
The reason for that the data is not at .gitconfig may that I have .gitconfig at my .gitignore -file.
Where does Git save the user’s secret tokens for github when they are not at Home’s .gitconfig?
GitHub uses SSH authentication so your tokens will be stored wherever your SSH client stores them. On Linux it would be under ~/.ssh.
I think you might mean where does git store the configuration information about your remotes? Usually it’s not in your ~/.gitconfig. Usually it’s in the “config” file under the “.git” directory in the root of your project.