Short status
- Git course
- Beginner
- Lesson 27/80
- 4 min
Learn the short status output with git status -s.
Use Short Status Output
git status -s displays repository status in a shorter, more compact format. It uses brief status indicators next to filenames instead of longer descriptions.
git status -sThe Advantage of Compact Output
Short status output takes up less space in projects containing many files. It is useful for quickly reviewing file states.
git status -s
M index.html
?? new.txtPractice Create a Short Status Command
Assign the git status -s command to the shortCommand variable. Then print the command.
Starter code
// Kısa durum komutunu tanımla
let shortCommand;
// Komutu yazdırSample solution
let shortCommand = 'git status -s';
console.log(shortCommand);Expected output
git status -s
Questions and answers
Review the lesson questions together with their answers. To test yourself, solve the lesson interactively.
1 Which command displays Git status in a short format?
- git status --local
- git status --global
- git status -s Correct answer
- git status -m
Explanation: The <code>-s</code> option enables short status output.
2 Complete the Short Status Option
git status ____
git status -s
Explanation: <code>-s</code> displays Git status in a short and compact format.
3 Match the Short Status Concepts
| Term | Meaning |
|---|---|
short_status |
Compact status view |
-s |
Short output option |
compact |
Use less text |
git status -s |
Short status command |