git-tree-path-portability-audit
Find case and naming conflicts in a committed Git tree before a Windows, Linux, or macOS checkout changes what is visible.
Try your first task
A source-grounded starter task has not been verified for this skill yet.
SKILL.md
name: git-tree-path-portability-auditdescription: "Find case and naming conflicts in a committed Git tree before a Windows, Linux, or macOS checkout changes what is visible."category: developmentrisk: safesource: selfsource_type: selfdate_added: "2026-12-02"author: Koushik-Katkamtags: [git, portability, release]Git Tree Path Portability Audit
Overview
Audit the bytes of an explicitly selected committed tree. Report exact collisions and names that need a target-platform review before publishing a source artifact. The result applies to the supplied evidence and the selected profile.
When to Use
- Use when a source release, case-only rename, or cross-platform checkout needs a filename audit.
- Review ZIP header encoding separately when the problem is how the archive presents a filename.
Prerequisites
Supply a NUL-delimited binary capture from Git 2.56.1. Use an authorized, hydrated local repository and an exact commit ID. The harness uses Python 3.12 and its standard library. Use the verification reference for the input contract and runnable block.
How It Works
1. Establish the inputs
Capture git ls-tree --full-tree -rzt <commit> as raw bytes using a binary-safe capture. Confirm the commit and the path scope. If a selected object is unavailable, record the missing capture before evaluating the tree.
2. Perform the task
Check every path component. Compare directory prefixes as well as complete filenames so a case conflict between two directories is visible. Review the Windows component rules and apply the explicitly selected case-fold and NFC comparison.
3. Verify the result
Report both spellings for a collision and the compatibility basis. Record which target filesystem configurations, checkout behavior and symbolic-link targets still need a separate check.
Examples
A release contains Src/a.c and src/b.c in different tree directories. The illustrative expected result is folded_path_collision on the directory spellings. Run python -I verify.py --self-test on the extracted reference. Audit the selected fixture or evidence with python -I verify.py --audit tree.bin.
Limitations
- The Win32 check covers a documented subset of component rules. Path-length policy and filesystem mount settings require separate evidence.
- Byte paths that are not UTF-8 are reported in hexadecimal. The audit does not follow symbolic links or interpret their targets.
- The Git record mode and object type follow the selected output format. Unicode NFC and case folding are compatibility heuristics for this audit.
Safety and side effects
Read only the specified capture. Do not check out the tree to create the inventory. Git capture, if authorized, should stay local and use an already hydrated repository with no lazy fetch.