Whether starting a solo project or working with someone else you got to have your things right.
The first step to configure Git is to configure your user name and email. We can do so by typing the following lines
git config --global user.name "My Name" git config --global user.email "My Email"
go to ssh folder on your computer and create a new one
cd ~/.ssh ssh-keygen -t ed25519 -C "My email"
you'll be asked many questions that you should read first but you can ignore those and just press enter for everyone.
now run the following command:
now you can get your public key and use it on Github/Gitlab/GitBucket. I'll be showing you how to do it on Github.
Now use the public key we got before.
Every time you feel needed to edit your
.gitconfig you can do so by running the following line on your terminal.
git config --global --edit
There is a lot of cool stuff we can configure on Git but I'll list some of them here and leave them for a new article.
git config --global init.defaultBranch master