mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-05-11 03:23:51 +00:00
feat(editor): add --list-by-magic to filter a tree to one specific format
Walks a directory recursively and lists every file matching a 4-character magic. Reports per-file size, entry count, catalog name, and relative path; aggregates total bytes + total entries across the matches. Useful for narrow per-format inventory: "show me all the WSPL spell catalogs in my project" or "find every WCDF that defines raid difficulty variants under my custom-content tree". The existing --summary-dir gives a multi-format rollup; this is the single-format zoom-in. Magic argument is case-insensitive — "WSPL" and "wspl" both match. If the magic is recognized in the format table the report header includes the format description and category; if not (e.g. a server-custom magic), the listing still works and just notes "unknown magic — no metadata". JSON sidecar via --json. Exit 1 if no matches (so it composes into shell "if any matches, do X" pipelines). This is the 17th cross-format utility: --list-formats / --info-magic / --summary-dir / --rename-by-magic --bulk-rename-by-magic / --touch-tree / --tree-summary-md --catalog-grep / --diff-headers / --audit-tree / --magic-fix --bulk-validate / --bulk-export-json / --bulk-import-json --diff-tree / --orphan-jsons / --list-by-magic CLI flag count 1032 -> 1033.
This commit is contained in:
parent
14c6a947ee
commit
6abd3f5398
6 changed files with 197 additions and 1 deletions
|
|
@ -139,7 +139,7 @@ const char* const kArgRequired[] = {
|
|||
"--catalog-grep", "--diff-headers", "--audit-tree",
|
||||
"--magic-fix", "--bulk-validate",
|
||||
"--bulk-export-json", "--bulk-import-json",
|
||||
"--diff-tree", "--orphan-jsons",
|
||||
"--diff-tree", "--orphan-jsons", "--list-by-magic",
|
||||
"--gen-animations", "--gen-animations-combat", "--gen-animations-movement",
|
||||
"--info-wani", "--validate-wani",
|
||||
"--export-wani-json", "--import-wani-json",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue