GH-900 · Question #106
Which of the following is the best description of a Git commit?
The correct answer is A. a snapshot of the entire repository at a specific point in time, capturing the state of all files in the. A Git commit is a snapshot of the entire repository at a specific point in time. When you commit, Git records the state of every tracked file-not just the changed lines-and stores a reference (SHA hash) to that snapshot. This is different from a delta-based system; Git…
Question
Which of the following is the best description of a Git commit?
Options
- Aa snapshot of the entire repository at a specific point in time, capturing the state of all files in the
- Ba record of the most recent changes made by a developer in Git
- Ca series of changes made to a file, or set of files, in Git
- Da log message that describes the purpose of the changes made to the files in a Git repository
How the community answered
(65 responses)- A94% (61)
- B2% (1)
- C2% (1)
- D3% (2)
Explanation
A Git commit is a snapshot of the entire repository at a specific point in time. When you commit, Git records the state of every tracked file-not just the changed lines-and stores a reference (SHA hash) to that snapshot. This is different from a delta-based system; Git reconstructs file states from snapshots. The commit also stores metadata like the author, timestamp, and commit message, but the core concept is the full repository snapshot.
Topics
Community Discussion
No community discussion yet for this question.