#include "SolverRequester.h"
+#include "Zypper.h"
+
// libzypp logger settings
#undef ZYPP_BASE_LOGGER_LOGGROUP
#define ZYPP_BASE_LOGGER_LOGGROUP "zypper:req"
if (ignore_pkgmgmt || patch->restartSuggested())
{
// bnc #221476
- if (_opts.skip_interactive && patch->interactive())
+ if (_opts.skip_interactive && patch->interactive(Zypper::instance()->globalOpts().reboot_req_non_interactive))
{
addFeedback(Feedback::PATCH_INTERACTIVE_SKIPPED, patchspec, selected);
return false;
"\t--rug-compatible, -r\tTurn on rug compatibility.\n"
"\t--non-interactive, -n\tDo not ask anything, use default answers\n"
"\t\t\t\tautomatically.\n"
+ "\t--reboot-not-interact\tDo not treat patches as interactive, which have\n"
+ "\t\t\t\tthe rebootSuggested-flag set.\n"
"\t--xmlout, -x\t\tSwitch to XML output.\n"
);
{"table-style", required_argument, 0, 's'},
{"rug-compatible", no_argument, 0, 'r'},
{"non-interactive", no_argument, 0, 'n'},
+ {"reboot-not-interact", no_argument, 0, '0'},
{"no-gpg-checks", no_argument, 0, 0 },
{"gpg-auto-import-keys", no_argument, 0, 0 },
{"root", required_argument, 0, 'R'},
MIL << "Entering non-interactive mode" << endl;
}
+ if (gopts.count("reboot-not-interact")) {
+ _gopts.reboot_req_non_interactive = true;
+ out().info(_("Patches having the flag rebootSuggested set will not be treated as interactive."), Out::HIGH);
+ MIL << "Patches having the flag rebootSuggested set will not be treated as interactive" << endl;
+ }
+
if (gopts.count("no-gpg-checks")) {
_gopts.no_gpg_checks = true;
out().info(_("Entering 'no-gpg-checks' mode."), Out::HIGH);
disable_system_resolvables(false),
is_rug_compatible(false),
non_interactive(false),
+ reboot_req_non_interactive(false),
no_gpg_checks(false),
gpg_auto_import_keys(false),
machine_readable(false),
bool disable_system_resolvables;
bool is_rug_compatible;
bool non_interactive;
+ bool reboot_req_non_interactive;
bool no_gpg_checks;
bool gpg_auto_import_keys;
bool machine_readable;
cout << "category=\"" << patch->category() << "\" ";
cout << "pkgmanager=\"" << (patch->restartSuggested() ? "true" : "false") << "\" ";
cout << "restart=\"" << (patch->rebootSuggested() ? "true" : "false") << "\" ";
- cout << "interactive=\"" << (patch->interactive() ? "true" : "false") << "\" ";
+ cout << "interactive=\"" << (patch->interactive(zypper.globalOpts().reboot_req_non_interactive) ? "true" : "false") << "\" ";
cout << "kind=\"patch\"";
cout << ">" << endl;
cout << " <summary>" << xml_encode(patch->summary()) << " </summary>" << endl;