Git Show Stat
Predict Output Medium
Question
What does this code print?
Code
git show --stat HEAD
# file.txt | 5 +-
# 1 file changed, 3 insertions(+), 2 deletions(-)
Hint
--stat shows a summary of changes.
Explanation
git show --stat HEAD shows the commit message and a summary of files changed, with insertion/deletion counts. This is useful for a quick overview without the full diff. Use --stat with git log for a history overview.
Related Resources
Related Lessons
- Git Log
Learn git log.
Look up unfamiliar terms
A beginner-friendly glossary explains jargon in plain English — variables, functions, DOM, Promise, and more.
Decode error messages
Plain-English explanations of common errors — what they mean, why they happen, and how to fix them.
Build real projects
Apply what you learned by building guided projects with starter code and solutions.