When I'm working on a project, one of my biggest fears is losing my work. So, I'm constantly saving my files and making backup copies. Back in the day, I used to do this manually. I would make copies and add the date, a version number, or sometimes a short description to the end of each file name. It was a mess! I had all these different files cluttering up my hard drive, but I didn't want to get rid of them, just in case I needed them again.
If you've ever found yourself creating files named "version1," "version2," or "final-version3," then you know what I'm talking about. It's not the easiest system to keep track of! Plus, there was always the worry that if something happened to my hard drive, all those files would be lost forever.
That's when I discovered Git.
What is Git?
Git is a distributed version control system and its main function is to manage project files and track changes. It does this without creating multiple physical files when tracking different versions. Instead, all changes are tracked within the same file.
Git keeps a history of these revisions, allowing you to review and compare the changes or even revert to a previous version if needed.
It doesn't have to be code-based files either. It can be anything, including PDFs, images, etc. The files can be stored locally and on a remote server, which can be used as a central location. This way, the files can be accessed from any computer, which is handy if you have multiple workstations or if you’re working with others. I often switch between my desktop and laptop so using Git helps to keep the files in sync and updated, even if I’m working by myself.
Getting started with Git
Here’s what you need:
Install Git on your computer
Sign up for a Git hosting service (GitHub, BitBucket, GitLab are some options)
Download a Git GUI (optional)
Here are some resources to get you started:
Git Tutorials by Atlassian
Watch my course! Programming Foundations: Version Control with Git. 🙂
In this course, I go over how to install Git, the overall concepts and terminology, the different ways to use Git (with a GUI and with the command line) and how to create and maintain changes in your Git repositories.
If you never want to deal with a file named "final-version3" again, git started today!
ICYMI, check out my YouTube series, Decoded by Christina.
Thanks for reading,
Christina 🙂