Compare $ARGUMENTS using drift --json and analyze the results.
How to run
drift --json <path-a> <path-b>
Optional: force a comparison mode with -m <mode> where mode is one of: tree, binary, plist, text. drift auto-detects the correct mode from the inputs - only use -m when the user explicitly requests a mode or auto-detection picks the wrong one.
Supported inputs
| Mode | Inputs | What it compares |
|---|---|---|
| tree | Directories, archives (.ipa, .apk, .aar, .jar, .tar, .tar.gz, .tar.bz2) | File tree with per-file status |
| binary | Mach-O executables and dylibs | Sections, sizes, symbols, load commands |
| plist | Property list files (.plist) | Structured key-value diff |
| text | Everything else | Line-by-line unified diff |
Steps
- Run
drift --json <path-a> <path-b>and capture the output - Start with
summaryto give an overview of what changed - For tree mode, walk the
rootto identify the most significant changes (largest size deltas, added/removed files) - For binary mode, focus on symbol changes and section size deltas - these indicate code/data growth
- For plist mode, highlight changed keys and their before/after values
- For text mode, summarize the hunks by theme (e.g. "updated imports", "refactored function X")
- Present size deltas in human-readable units (KB/MB)
When the output is large, use jq to extract specific parts rather than dumping everything. See reference.md for the JSON schema and useful jq recipes.