| name | standardize |
| description | Auto-standardize a MD focus/event/decision/idea/MIO file with the tools/standardization/ scripts and report what changed. Use when asked to standardize, reformat, or bring a mod file up to MD conventions. Takes the file path as argument. |
Standardize a Millennium Dawn mod file using the standardization tools.
File to standardize: $ARGUMENTS
Steps:
-
Determine the file type from the path:
common/national_focus/ or filename contains "focus" → focus
events/ → event
common/decisions/ → decision
common/ideas/ → idea
common/military_industrial_organization/organizations/ → mio
If the type cannot be determined, ask the user to clarify.
-
Run from the tools/standardization/ directory:
python3 standardize.py <type> <absolute_file_path> --backup --verbose
-
Report what changed: list each block that was reformatted and what was fixed (missing logging, property reordering, removed performance-hurting patterns, etc.)
-
If any issues were warned about but not auto-fixed, list them so the user can address them manually.