[elbe-devel] [PATCH 3/5] elbepack: imgutils: switch to shellhelper.run
Thomas Weißschuh
thomas.weissschuh at linutronix.de
Tue May 28 12:38:50 CEST 2024
Remove the last caller of shellhelper.get_command_out().
Signed-off-by: Thomas Weißschuh <thomas.weissschuh at linutronix.de>
---
elbepack/imgutils.py | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/elbepack/imgutils.py b/elbepack/imgutils.py
index c7182d733be0..635b3e68e7a9 100644
--- a/elbepack/imgutils.py
+++ b/elbepack/imgutils.py
@@ -5,14 +5,15 @@
import contextlib
import subprocess
-from elbepack.shellhelper import do, get_command_out
+from elbepack.shellhelper import ELBE_LOGGING, do, run
@contextlib.contextmanager
def losetup(dev, extra_args=[]):
- loopdev = get_command_out(
- ['losetup', '--find', '--show', '--partscan', *extra_args, dev]
- ).decode('ascii').rstrip('\n')
+ loopdev = run(
+ ['losetup', '--find', '--show', '--partscan', *extra_args, dev],
+ stdout=subprocess.PIPE, stderr=ELBE_LOGGING,
+ ).stdout.decode('ascii').rstrip('\n')
try:
yield loopdev
--
2.45.1
More information about the elbe-devel
mailing list