Skip to content

Commit

Permalink
vmupdate/dnf: use --setopt=obsoletes=1 instead of --obsoletes
Browse files Browse the repository at this point in the history
DNF5 dropped that CLI option, but the config option remained:
https://github.com/rpm-software-management/dnf5/blob/main/doc/changes_from_dnf4.7.rst

QubesOS/qubes-issues#9244

(cherry picked from commit a5eb27d)
  • Loading branch information
marmarek committed Nov 5, 2024
1 parent ddd42e9 commit ef23fa4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion vmupdate/agent/source/dnf/dnf_cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ def get_action(self, remove_obsolete) -> List[str]:
Disable or enforce obsolete flag in dnf/yum.
"""
if remove_obsolete:
return ["-y", "--obsoletes", "upgrade"]
return ["-y", "--setopt=obsoletes=1", "upgrade"]
return ["-y", "--setopt=obsoletes=0",
"upgrade" if self.package_manager == "dnf" else "update"]

Expand Down

0 comments on commit ef23fa4

Please sign in to comment.