The commands below are only valid for the current project unless you use –global then folders without user id will use the global parameter:
git config user.name "My name"
git config user.email "mymail@gmail.com"
You might also appreciate these, useful for dealing with files coming from Windows:
git config core.autocrlf false
git config core.ignorecase true
git config core.fileMode false
Do you use git in the cloud? how about 8h without typing the password again? Or 86400 for 1 full day
git config credential.helper store
git config credential.helper 'cache --timeout=28800'
But on linux this doesn't work anymore, so it is necessary to give permission to the operating system as its key holder for these operations so use the following command:
sudo dnf install git-credential-libsecret
git config credential.helper /usr/libexec/git-core/git-credential-libsecret
Of course the first 'git push' will still need your credentials, but not later.