1. What does a CODEOWNERS file typically enforce?
CODEOWNERS maps paths to responsible reviewers and can be required by branch rules.
Get the Preplance app for a seamless learning experience. Practice offline, get daily streaks, and stay ahead with real-time interview updates.
Get it on
Google Play
4.9/5 Rating on Store
Git & Version Control · Question Set
Branching Strategies, Pull Requests & Collaboration interview questions for placements and exams.
Questions
13
Included in this set
Subject
Git & Version Control
Explore more sets
Difficulty
Mixed
Level of this set
Go through each question and its explanation. Use this set as a focused practice pack for Git & Version Control.
CODEOWNERS maps paths to responsible reviewers and can be required by branch rules.
For complete preparation, combine this set with full subject-wise practice for Git & Version Control. You can also explore other subjects and sets from the links below.
Squash condenses all PR commits into one for a tidy history.
Merging preserves history and is non-destructive but adds merge commits. Rebasing keeps a linear history but rewrites commits and requires force-push to the PR branch.
Review promptly, be specific and kind, ask clarifying questions, suggest concrete changes, verify tests/docs, pull locally when needed, and approve only after required checks pass.
Branches isolate work (features, fixes, experiments), keep main stable, enable review and CI per branch, and simplify rollback/cleanup without risking production code.
Git Flow uses persistent main and develop branches; feature/release/hotfix are short-lived.
Require PR reviews, require status checks (CI) to pass, disallow force-pushes, require up-to-date with base, enforce signed commits, and restrict who can push.
Clear title, description (problem, approach, scope), links to issues/tickets, screenshots/logs, test notes, checklist, and small, focused commits.
Draft PRs invite early review without merge intent.
They’re easier to review, reduce cycle time, lower defect risk, improve merge success, and aid revertability.
Rebase+merge rewrites branch commits on top of base to keep history linear.
Keywords like “Fixes/Closes/Resolves #id” close the issue on merge to default branch.
GitHub Flow favors small feature branches off main with PR review and continuous delivery.