Progress:
TIER 2 · MODULE 15· Intermediate

git bugreport

Dumps environment, version, config — for filing bugs upstream.

🎯 What & why

git bugreport produces a pre-filled bug report — Git version, build details, OS, key config, and (optionally) repo diagnostics — so you stop wasting maintainers' time guessing your environment.

🧠 Mental model

A git --version on steroids that writes a Markdown-ish file ready to paste into the Git mailing list or an issue tracker. Pure data dump, no upload, no telemetry.

🛠️ Synopsis

git bugreport [-o | --output-directory <path>]
              [-s | --suffix <format> | --no-suffix]
              [--diagnose[=<mode>]]

🎚️ Switches & options

FlagWhat it does
`-o <dir>` / `--output-directory <dir>`Where to write the report. Defaults to the current directory.
`-s <fmt>` / `--suffix <fmt>`strftime-style suffix for the filename (default %Y-%m-%d-%H%M).
`--no-suffix`Omit the suffix entirely — file becomes git-bugreport.txt.
`--diagnose[=stats|all]`Also produce a zip archive with repo diagnostics. stats = sizes/object counts; all = adds loose-ref listings and packed-refs. !all may include sensitive ref names.

💡 Use cases

🧪 Examples

Default report in CWD
git bugreport
Write into ~/reports
git bugreport -o ~/reports
Stable filename, no timestamp
git bugreport --no-suffix -o /tmp
With repo diagnostics zip
git bugreport --diagnose=stats -o /tmp

🎓 Recommendations

🪤 Common pitfalls

🔗 Related modules

📝 Quiz

Hit each option, then Check answers. Score is recorded; Next is always open.