Version Control & Git Workflow
Git is the shared memory of every software team. Beyond the basic commands (init, clone, add, commit, branch, merge, pull, push), what actually matters day to day is a working feature-branch workflow with pull or merge requests, recognising and resolving merge conflicts, and the discipline of clear commit messages and a proper .gitignore — the practical basis for collaborating on GitHub or GitLab.
Starting Points
- Chacon, S., & Straub, B. Pro Git (2nd ed.). Apress, 2014 (free at git-scm.com).
- learngitbranching.js.org
- GitLab Docs. "Getting started with Git" and "Merge requests".
- GitHub Docs. "Hello World" and "Collaborating with pull requests".
Key Points
- You use Git locally to track changes, with clear, meaningful commit messages.
- You work with a remote repository: cloning, pulling from main/master, and pushing local commits.
- You implement a feature-branch workflow, including opening a pull or merge request.
- You resolve basic merge conflicts by inspecting conflicting changes and completing the merge correctly.
- You use
.gitignoreto keep generated files, build artefacts, and secrets out of the repository. - You collaborate through GitHub or GitLab: reviewing changes, responding to comments, and using issues to coordinate work.