loading...

Want To Learn Programming? Learn How To Track Changes First

sublimegeek profile image Jonathan Irvin ・3 min read

Disclaimer: For the sake of this article, we are going to use Git as an example.

Git is a tool used to track changes in your source code, right down to the letter! And naturally, people like to throw acronyms around, that relate to it. You might see Git labeled as a VCS or SCM which means Version Control System or Source Code Manager, respectively. Both are correct and both neither tell you what Git actually does.

Git came out about the time I started learning the ins and outs of web design, which was 2005. I was recently discharged from the Air Force and looking to fill that gaping hole and structured life the military left me without. I got to see what life was like with and without Git.

At the time, I had a mentor in California (I called him my scripting sensei) that introduced me to Git and effectively changed my programming life forever. Since then, I've been a huge advocate of using source control, especially Git.

Without Git, or any form of source control, you are either just saving your files and blinking at your screen, or you are taking the entire folder of your workspace and making copies of it. You have your backups and your backups of backups. Maybe you date the folders or label them "FINAL-Final-UGHHHHHH-v23".

Humans, like computers, have a finite amount of storage. I, for one, can barely remember what happened 5 minutes ago, let alone remember that block of code I accidentally wiped out and started over with 5 or 6 times. Learning something new is frustrating to begin with. You have your ups and downs, your wins and your losses, your "I don't knows" and your "I'll figure it out laters". Learning something without a solid foundation is like cupping sand in your hands. Maybe you can for a little while, but eventually the sand slips through your fingers and is lost.

Once you know Git, it's like building a brick house. Each time you commit code to your repository, you are laying bricks down. When you have built your application to the point that it breaks, the wall you made falls down. Without Git, you have to start over from some arbitrary point in your code where you knew it was working, where your wall was still standing.

With Git, you can branch off of a working point in time and add to it. You can have as many branches as you want. You can experiment in different ways and keep the code that works best.

Also, as you are adding to your code, you can work on more than one thing at a time and switch between tasks, coming back to where you left off.

Git is a fundamental skill. Later on in your programming career, you will find Git is used for everything from collaboration to automation.

Even if you are an average programmer, being a master at Git can get you out of just about any bug since you can always go back to where you were before and take a different route that will work better.

Too many times I've seen great programmers just get utterly crippled by lack of Git knowledge. Hours upon days of work lost from one bad merge.

So, getting back to the time frame, I've used Git for some time. I was your unorthodox programmer going to college well after High School and by the time I was a Senior, I was shocked to learn our college still had not taught source control management. As somewhat of an "exit interview" at the beginning of my last semester, one new professor asked me what I thought was the most important skill new Computer Science students are missing. Hands down, I suggested Git. I co-taught the freshman CS 1 class and introduced them to the wonders of Git. Everyone, even non-CS majors, were impressed by how simple and powerful Git was. To this day, my college uses Git as a core part of their curriculum.

I believe that mastering Git is quintessential in the success of future and current programmers. If you are just starting out or curious about being a programmer, I encourage you to take a break and master the ins and outs of Git. Learn it backwards and forwards from the command line. Learn the most common commands, create aliases for the ones you use most often. Visually see what is happening in your repository with every commit you make.

Posted on by:

sublimegeek profile

Jonathan Irvin

@sublimegeek

I'm a full-stack cloud-minded engineer who enjoys devops and clean code.

Discussion

pic
Editor guide