QuestionQ13

701.3 Source Code Management

Which of the following statements are correct about the commands git diff and git diff --staged?

Choose two
Explanation

git diff shows differences between the working tree and the index, which are changes not added to the next commit. git diff --staged (equivalent to git diff --cached) shows differences between the index and HEAD, which are the changes staged for inclusion in the next commit.

Learn more

Community Discussion

No comments yet. Be the first to start the discussion!