WordPressCli wpCli = WordPressCli.getDefault(true);
Future<Integer> result = wpCli.coreUpdate(phpModule, Collections.<String>emptyList());
if (result != null) {
result.get();
}
result = wpCli.coreUpdateDb(phpModule);
if (result != null) {
result.get();
}
} catch (InvalidPhpExecutableException ex) {
Exceptions.printStackTrace(ex);