Git Please! An Introduction to Version Control

thequeenbeebs
3 min readJul 2, 2021

--

Photo by David Wirzba on Unsplash

Even if you are just a newbie software engineer, I’m sure that you have or at least are familiar with GitHub, which is a website that helps developers store and manage their code with something called version control. Today I’m going to break down version control and explain why it is so important.

What is version control?

Version control is, simply, a program that tracks changes in a project (or what we call a repository). This is crucial for software engineering teams to help them work smarter and faster, so multiple engineers can work on the same repository at once.

Think about all of the group projects you had to do in school as a kid. I don’t know about y’all, but it often involved a poster board and a presentation. We would all work on it together at school, but inevitably someone would have to take it home at the end of the day and maybe even finish the work on their own, without final collaboration of the other partners (let’s be real — that was usually the overachiever me over here). If this happened with an engineering team, I just picture a bunch of people huddling over one monitor and yelling at a single person typing…it wouldn’t be good. Version control enables every member of the team to essentially “take home” the project; each engineer has a branch (or copy) of the repository on their machine, that can then be merged to create the final project.

Advantages of Version Control

1. Makes backups.

Accidentally delete a crucial file that you need for your project? Not a problem. Version control essentially makes a backup that you can go back to if you make a snafu.

2. Gives engineers a history of the project.

This is incredibly useful if you happen to walk away from code for awhile, need to update outdated code, or general debugging.

3. Can trace each change made.

When you are in the groove, it can be hard to even remember what all you actually changed! With version control, you can compare the code you have written to the main branches code with ease to see the work you have done.

4. Allows you to experiment without risk.

Adding a new feature to a project can sometimes seem a little risky, with a fear that you might “break” the main code in the project. With version control and branching, you can build out your own branch for just that feature, and if it turns out to be a bust and breaks the main code, just throw it in the bin and go back to the working code you had before.

5. Makes collaboration 100 times easier.

Like I mentioned above in the poster project example, this is the main way I have found version control to be helpful so far. When I was studying at my bootcamp, we were frequently put into pairs for large projects. If we chose the “divide and conquer” method, rather then just screen sharing and coding together, we could get the project completed in almost half the amount of time. We would create our branches, and just merge them together at the end of each day. Easy peasy.

There are many different methods of version control, but the most popular is called Git (which is what GitHub uses). If you haven’t used version control before, I would highly recommend getting started with Git! There are some fabulous tutorials all over the internet, including this very dense set of labs I like called Git Immersion. Check it out; I promise version control will save you from headaches in the long run! Happy coding!

--

--

thequeenbeebs
thequeenbeebs

Written by thequeenbeebs

Blaire is a musical theatre performer who also moonlights as a full-stack software engineer. https://www.linkedin.com/in/blaire-baker

No responses yet