BEGINNER'S GUIDE TO GIT: PUSH, PULL AND TRACKING CHANGES
Source: Dev.to
Version Control (git)
Git lets you keep a single file while recording every change you make.
In Git, saving isn’t just hitting Ctrl + S—it’s a three‑step process:
- Modify your code.
- Stage the changes you want to keep.
- Commit the staged changes with a descriptive message (e.g., “fixed the login button”).
Think of it like downloading updates: you first get the latest changes, then you make your own, and finally you share them.
git pull
git pull fetches the newest changes from the remote repository and merges them into your local branch.
It’s similar to checking your email for new documents that teammates have sent.
git push
git push uploads your local commits to the remote repository so others can see them.
It’s like sending an email with your updated document to the team.
Beginner’s workflow cycle
- Pull – Get the latest updates from your team.
- Code – Write your amazing code.
- Commit – Record your changes locally with a descriptive note.
- Push – Send your changes up to the cloud for everyone else.