[elbe-devel] [PATCH v2 13/15] Change os.sytem to shellhelper::system for "virtapt.py"

dion at linutronix.de dion at linutronix.de
Mon Jun 24 17:39:10 CEST 2019


From: Olivier Dion <dion at linutronix.de>

Signed-off-by: Olivier Dion <dion at linutronix.de>
---
 elbepack/virtapt.py | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/elbepack/virtapt.py b/elbepack/virtapt.py
index e382c688..8678baa2 100644
--- a/elbepack/virtapt.py
+++ b/elbepack/virtapt.py
@@ -12,9 +12,10 @@ import os
 import sys
 
 from tempfile import mkdtemp
-
 from multiprocessing.managers import BaseManager
 
+from elbepack.shellhelper import system
+
 # don't remove the apt import, it is really needed, due to some magic in
 # apt_pkg
 
@@ -128,7 +129,7 @@ class VirtApt(object):
             print(e)
 
     def __del__(self):
-        os.system('rm -rf "%s"' % self.projectpath)
+        system('rm -rf "%s"' % self.projectpath)
 
     def start(self):
         pass
@@ -153,7 +154,7 @@ class VirtApt(object):
         else:
             os.makedirs(newdir, mode)
             # mode is not set correctly
-            os.system("chmod 777 " + newdir)
+            system("chmod 777 " + newdir)
 
     def touch(self, fname):
         if os.path.exists(fname):
-- 
2.11.0




More information about the elbe-devel mailing list