I confirm:
git config --global user.name "Joana Dine"
This is only one of the three place Git will look for for identifying your commit done locally (on your workstation).
This is not related to GitHub.
This is related to the commit author and committer name for each of the commit you are creating locally.
If you want GitHub to show said commits as yours, once pushed on your GitHub repo, then sure, you should set your user.name and user.email to the same values than the one associated with your GitHub account.
But nothing prevent you to make commits as "foo
" (git config --global user.name "foo"), and then pushing them using your GitHub credentials.
The two (commits name and GitHub credentials) aren't linked at all.
The "To change my name" should be understood as "To change my name locally for my new commits".
The only time GitHub will need credentials is when you are pulling/pushing a GitHub repo, in which case it will use the credentials used in $HOME/.netrc
(or %HOME\_netrc
on Windows, provided you did defined HOME
, which isn't defined by default on Windows): see "Syncing with github".