Git is a distributed version control system (DVCS) used to track changes in source code during software development. It allows multiple developers to collaborate, maintain version history, and manage code efficiently.
You need to add a new feature and want to keep your work isolated. How would you use Git to start that work?
If you accidentally modify a file and haven't committed yet, what Git command would you use to discard those changes?
When you run git status and see 'untracked files', what does that mean and what would you do next?
During a sprint, a teammate's merge caused a conflict in config.yml. Walk me through how you'd resolve it and ensure the merge stays clean.
You notice that after pulling the latest changes, your local tests are failing. How would you investigate whether the issue is due to a recent commit or a merge problem?
Our CI pipeline is failing because the repository's history has grown large. What Git strategies could you employ to reduce repo size without losing history?
Our monorepo now contains several hundred microservices, and developers complain about long clone times. How would you redesign the Git workflow or repository layout to improve scalability?
We need to enforce a policy that only signed commits are allowed on the main branch. Describe how you'd implement this at the repository level and what tooling you'd use.
A release branch has diverged significantly from main over months. What steps would you take to safely integrate critical fixes from main into the release branch while preserving release history?
Our organization is migrating from a legacy Perforce system to Git across dozens of teams with different workflows. What high‑level migration plan would you propose, and how would you address cross‑team coordination, history preservation, and tooling adoption?
We want to adopt a trunk‑based development model but have many existing long‑living feature branches. How would you transition the codebase and culture, and what Git features would you leverage to minimize disruption?
Given the need for auditability and compliance, how would you design a Git‑centric architecture that supports immutable release artifacts, signed tags, and integrates with our CI/CD pipeline at scale?