PluginWrapper pluginWrapper = getPlugin(id);
if (pluginWrapper == null) {
throw new UnloggedFailure("Invalid plugin specified!");
}
if (gitblit.disablePlugin(pluginWrapper.getPluginId())) {
stdout.println(String.format("Disabled %s", pluginWrapper.getPluginId()));
} else {
throw new UnloggedFailure(1, String.format("Failed to disable %s", pluginWrapper.getPluginId()));
}
}