zip = (String)operands.firstElement();
}
if (rootDir==null || target==null || zip==null) {
throw new CommandValidationException(_strMgr.getString(
"InvalaidApplyRepositoryCommandConfiguration"));
}
// target name will be part of root dir
if (rootDir.indexOf(target) > 0) {
Unzipper z = new Unzipper(rootDir);
z.writeZipFile(zip);
// successful msg
CLILogger.getInstance().printDetailMessage(
_strMgr.getString("ApplyRepositoryZipCommandSuccessful",
new Object[] {name, zip}));
} else {
throw new CommandValidationException(_strMgr.getString(
"InvalaidRootDir", new Object[] {rootDir, target}));
}
} catch (Exception e) {
e.printStackTrace();