Renames Cargo package, binary, internal path identifiers, java shim, user-agent, log filename, desktop shortcut Exec lines, and CLI program name. Wires src/migrate.rs into main() so existing users have their on-disk data (~/.config/mcl/, ~/.local/share/mcl/, ~/.cache/mcl/) moved to the new locations on first launch. BREAKING CHANGE: binary is now named rmcl. Old paths are auto-migrated.
20 lines
663 B
Java
20 lines
663 B
Java
import java.lang.reflect.Method;
|
|
|
|
public class RmclShim {
|
|
public static void main(String[] args) throws Exception {
|
|
if (args.length == 0) {
|
|
System.err.println("Usage: RmclShim <mainClass> [args...]");
|
|
System.exit(1);
|
|
}
|
|
|
|
String mainClass = args[0];
|
|
String[] remaining = new String[args.length - 1];
|
|
System.arraycopy(args, 1, remaining, 0, remaining.length);
|
|
|
|
ClassLoader loader = ClassLoader.getSystemClassLoader();
|
|
Class<?> clazz = loader.loadClass(mainClass);
|
|
Method main = clazz.getMethod("main", String[].class);
|
|
main.invoke(null, (Object) remaining);
|
|
}
|
|
}
|