cmds.distro.backend.debian.Util.py: Add dpkg()

Add utility method .dpkg() to the backend.debian.Utils class, saving
the need to import it, saving the need to import it.

Signed-off-by: Jan Lindemann <jan@janware.com>
This commit is contained in:
Jan Lindemann 2026-03-04 14:44:03 +00:00
commit a7293e0ac9

View file

@ -1,6 +1,7 @@
# -*- coding: utf-8 -*-
from ...Cmd import Cmd
from ...lib.dpkg import run_dpkg
from ..Util import Util as Base
class Util(Base):
@ -16,3 +17,6 @@ class Util(Base):
mod_env = { 'DEBIAN_FRONTEND': 'noninteractive' }
cmd.extend(args)
return await self._sudo(cmd, mod_env=mod_env)
async def dpkg(self, *args, **kwargs):
return await run_dpkg(*args, **kwargs)