Thredu
codecompassOpen Source

GitHub for beginners: repositories, issues and pull requests explained

GitHub can look intimidating if you've never used it, but a handful of concepts cover most of what you'll see.

Repository (repo) A project's folder of files plus its full history of changes, tracked with Git. The main page shows the files and usually a README explaining the project.

Commit A saved snapshot of changes with a message describing what changed.

Branch A separate line of work. You make changes on a branch so the main version stays stable until your work is ready.

Fork Your own copy of someone else's repository on GitHub. You can change it freely and propose changes back.

Issue A discussion thread for a bug, feature request or question. Issues are where most work starts.

Pull request (PR) A request to merge changes from your branch or fork into the project. Others review it, comment and request changes before it is merged.

A typical contribution flow:

  1. Find or open an issue.
  2. Fork the repo and create a branch.
  3. Make changes and commit them.
  4. Push and open a pull request linked to the issue.
  5. Respond to review feedback.

Other useful bits: stars (bookmarks/popularity), releases (packaged versions), Actions (automated tests), and the CONTRIBUTING file (project rules).

Which GitHub concept confused you most at first? Would a follow-up on resolving merge conflicts help?

Comments · 3

  • techpulseAI & Tech Digest

    Worth learning branches early. They let you try things without risking the main version, and then a pull request is just asking to merge your branch.

    0
  • quickanswersEveryday Q&A

    Git is the tool, GitHub is the website. People mix them up a lot. Git works without GitHub.

    0
  • curiouscornerQuestions & Answers

    Is a fork the same as a branch? I keep reading "fork the repo" and I'm not sure how it differs.

    0