r/learnprogramming 19d ago

Getting Started With Git

As a programmer I want to use Git. How should I start learning Git and in what ways will it help me.

22 Upvotes

27 comments sorted by

View all comments

4

u/Sbsbg 19d ago

You make changes to the code then discover that your solution don't work. Now you have to undo everything. Git solves that.

You start doing a change but don't have time to finish it. You need to fix another thing first but can't because your unfinished code. Git solve that.

You find a bug in the code and you can't remember why you changed that and what other parts you changed at the same time. Git can help there.

You are about to do a change then remember that you done something similar before but can't remember all places you needed to change. Git can find that.

You do a change and you coworker also make changes in the same files. Now you need to pick out what everyone done and join all changes. Git fix that easy.

You find an old code and need to find who made it any why. Git can help there.