Parses the output of git status --porcelain -z (v1 format) into a status object.
This is a pure function that can be tested independently.
Format: XY path\0 where:
- X = staged status (index)
- Y = unstaged status (work tree)
- path = file path (unescaped with -z)
Supported status codes:
- M = modified
- A = added
- D = deleted
- R = renamed
- C = copied
- T = type changed (regular file, symbolic link or submodule)
- U = unmerged
- ? = untracked
- ! = ignored
For renames/copies: XY new\0old\0 (two NUL-separated paths)
Note: This implementation treats submodules the same as regular files.
Submodule-specific status codes (lowercase m, ?) are interpreted as changes.