modernize-assess
Mode. If $ARGUMENTS starts with --portfolio, run Portfolio mode on the
directory that follows. Otherwise run Single-system mode on $system, the
first token. Flags go after it (<system> --show-secrets): a flag in first place
would be read as the system name.
The code is legacy/$system, often a symlink to where it really lives: say where it points (readlink legacy/$system) in one line before you start. If legacy/$system does not exist, stop and say so: nothing can run without the code, so the fix is /code-modernization:modernize $system --source <path to the code>. Run every subagent in the foreground and wait for its result: never end your turn while one is still running.
Portfolio mode (--portfolio <parent-dir>)
Sweep every immediate subdirectory and produce a heat-map a steering committee can use to sequence a multi-year program.
If the Workflow tool is available (this command is your authorization),
list the subdirectories first (ls -d <parent-dir>/*/ | xargs -n1 basename; the
script has no filesystem access), tell the user the count (30 systems means 30
agents), then run one survey agent per system: