Learn Git
New to Git? Start here. Every idea — commits, branches, push, pull, pull requests, merging — explained simply, with everyday examples for students and new engineers.
New to Git? Start here. Every idea — commits, branches, push, pull, pull requests, merging — explained simply, with everyday examples for students and new engineers.
Git is a tool that remembers every version of your project, so you never lose work and can always see who changed what, and why.
A repository — everyone says "repo" — is a project folder that Git is watching. It holds your files *and* the full history of every change ever made to them.
A commit is a snapshot of your project at one moment, with a short note explaining what changed. It's the single most important idea in Git.
A branch is a separate line of work. It lets you build a new feature or try an idea without disturbing the working version of the project.
Cloning means downloading a full copy of a repository — all its files *and* its entire history — from a server onto your laptop, so you can start working on it.
A remote is a version of your repository that lives somewhere else — usually on a server like Sangam-Git — that you and your team sync with. It's the common meeting point for everyone's work.
Push sends your commits up to the shared server. Pull brings your teammates' commits down to your laptop. Together they keep everyone's copy in sync.
A pull request (PR) is how you ask for your branch to be reviewed and added to the main project. It's the front door for every change on a team — a place to show your work, get feedback, and get approval before it becomes official.
Merging takes the commits from one branch and joins them into another. It's how a finished feature branch becomes part of `main`.
A merge conflict happens when two branches changed the *same lines* of the *same file* in different ways. Git can combine most changes on its own, but when two edits clash, it stops and asks a human to decide. That human is you — and it's easier than it looks.
Merge and rebase both bring one branch's changes into another. The difference is what they do to your project's history: merge *joins* the two timelines; rebase *replays* your commits on top of the other branch to make one straight line. Beginners can happily use merge and ignore rebase for a while — but here's what rebase is, so it stops being mysterious.
You've met all the pieces — repo, commit, branch, clone, push, pull, pull request, merge. Here's how they fit into one normal working day at a software team. Follow this rhythm and you'll look like you've done it for years.