r/git • • 11d ago

What's the best way to learn Git and GitHub effectively?

I'm looking to learn Git and GitHub from scratch. What's the best way to learn them effectively? Which resources would you recommend, and how should I practise to become comfortable using them in real projects? I'd appreciate advice from people who have learned them or use them regularly.

5 Upvotes

12 comments sorted by

5

u/joranstark018 11d ago

Many tools, like Github, add their own abstractions on git so it can become unclear what git provides and what the tool provides. My advice is to read the book "Pro Git" (or any of the other resources in the sidebar) to get an understanding of the basics of git. 

Github has plenty of tutorials on how to use Github, eg https://docs.github.com/en/get-started/using-github/hello-world, just remember to differentiate Github from git.

1

u/Revolutionary-Draw43 11d ago

Best way is to start using git / gh and try to understand it along the way. Make a repository for notes for example, and commit often, ideally from more than one machine. Big part of the everyday usage of git is fairly simple, and it's easier to learn the more complex stuff when you're already familiar with the tool imo.

1

u/smashcat666 10d ago

There's not really much point - it's like learning the intricacies of cmake or yaml files for a project - just let the IDE handle it, or let an LLM (or even a GUI app) handle git issues. Otherwise you're just wasting time fiddling with a tool that's never really been designed for humans to interact with, when you could be doing something interesting. If you're working on a server where you only have the command line, the most you'd be doing is pulling updates anyway,

1

u/StephenHawkinguss 10d ago

Maybe by using it? What kind of question is that?

1

u/Antonio-MTS 9d ago

Create a Github account, then create repos there and start some development of any software you can write adding code to the repos created. Every known git platform like Github, Bitbicket, Gitlab etc has got good tutorials on its usage with git. They can be your starting point in git journey. Good luck 🤞

1

u/bgeeky 9d ago

I never understood this type of learning. You have to start by realizing these are tools and learning the tool is separate from learning how to accomplish something and finding the right tools to do that.

1

u/destroyerpants 9d ago

Read the git man pages, find a topic in GitHub your interest in, read the documentation Like read about a specific thing, then use it in a few different ways.  Git is a supporting tool, you have to be building something to use git. So build something while you are at it 

1

u/J_Galang 9d ago

depends on your learning style. learning by doing usually drives the best results.

there are plenty of free tutorials online if you're more of a visual learner.

but here's the best of both worlds. heres a website that walks you through the concepts and helps you execute them visually: https://learngitbranching.js.org/

its sort of similar to flexbox froggy and grid garden for learning css attributes.

hope this helps.