Rename a Java class or interface across all file types in the eMedia codebase and verify with a full build.
Usage: /rename [OldName] [NewName]
Parse the arguments: first token is the old class name, second is the new class name.
Use Grep to find EVERY reference to OldName in:
**/*.java — class names, imports, type references, Javadoc**/pom.xml — artifact names, mainClass in plugins, surefire includes**/*.xml — Spring XML bean definitions, CXF config, log4j2 config**/*.yaml, **/*.yml — Spring config with FQCN references**/*.properties — fully-qualified class references, Wicket i18n keys**/*.html — Wicket HTML templates referencing class namesBefore touching any file, output a table:
| File | Line | Context |
|---|---|---|
| ... | ... |
| ... |
Include a total count. Wait for implicit confirmation to proceed (do not ask — just proceed after showing the plan).
Apply changes in this order:
Work module by module. After editing each module's files, run:
mvn compile -pl <module> -q
Report pass/fail before moving to the next module.
After all modules compile:
mvn clean install -q
If any compilation errors occur, read the error, identify the missed reference, fix it, and recompile — do NOT stop and ask.
Output a summary: