mirror of https://github.com/zlatinb/muwire
pass MW home to the client
parent
562d9a0f4a
commit
5d2d831b9e
|
@ -3,4 +3,4 @@ clientApp.0.name=MuWire
|
|||
clientApp.0.startOnLoad=true
|
||||
clientApp.0.delay=5
|
||||
clientApp.0.classpath=${libname}
|
||||
clientApp.0.args=version=${version}
|
||||
clientApp.0.args=version=${version} home="\$PLUGIN"
|
||||
|
|
|
@ -11,6 +11,7 @@ public class MuWireClient implements RouterApp {
|
|||
private final ClientAppManager mgr;
|
||||
private final String[] args;
|
||||
private final String version;
|
||||
private final String home;
|
||||
|
||||
private ClientAppState state;
|
||||
|
||||
|
@ -19,12 +20,16 @@ public class MuWireClient implements RouterApp {
|
|||
this.mgr = mgr;
|
||||
this.args = args;
|
||||
String version = null;
|
||||
String home = null;
|
||||
for (String arg : args) {
|
||||
String [] split = arg.split("=");
|
||||
if (split[0].equals("version"))
|
||||
version = split[1];
|
||||
else if (split[0].equals("home"))
|
||||
home = split[1];
|
||||
}
|
||||
this.version = version;
|
||||
this.home = home;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
Loading…
Reference in New Issue