Many of my readers are developers. Sometimes we have needed to work with projects with code that does not want to share with the world. GitHub is the hub to save all the changes in our projects with a great version control system, but unless you want to checkout, all repositories that you think it will be open to the public.
If you want to store the changes you're making in your code with Git system on Raspberry Pi privately, read on...
The steps are complex and requires that you follow each of them without committing a fault, otherwise you might destroy your Raspberry Pi, ...naah!, just kidding. I thought it was something more complex because I am not an expert on Git. Just only use a few commands daily.
What I have done is create you a simple script to execute this in your favorite distro and I've uploaded to PiKISS
I leave the script below just in case you want to take a look: