GH-900 · Question #4
GH-900 Question #4: Real Exam Question with Answer & Explanation
The correct answer is A: Committed. In a Git repository, a file can be in one of the following three valid states: Committed: The file is saved in the local repository. It is part of the permanent history of the Modified: The file has been changed but not yet staged or committed. It is in the working Staged: The fi
Question
What are three valid states for a file in a git repository? (Choose three.)
Options
- ACommitted
- BModified
- CUncommitted
- DStaged
- ETracked
Explanation
In a Git repository, a file can be in one of the following three valid states: Committed: The file is saved in the local repository. It is part of the permanent history of the Modified: The file has been changed but not yet staged or committed. It is in the working Staged: The file has been marked to be included in the next commit. It is in the staging area, ready to be committed. These states represent the typical lifecycle of a file as it moves through the process of being edited, reviewed, and saved in Git.
Topics
Community Discussion
No community discussion yet for this question.