summaryrefslogtreecommitdiffstats
path: root/draklive
diff options
context:
space:
mode:
authorMartin Whitaker <mageia@martin-whitaker.me.uk>2018-01-10 09:03:20 +0000
committerMartin Whitaker <mageia@martin-whitaker.me.uk>2018-01-12 08:44:42 +0000
commitff30da3ebb107421372e2a1a6d37f7c189667f2b (patch)
tree7dcb10f555e74768f55029d644d16e636abb5420 /draklive
parent98ac027245772b49c24b1bbe35b0f33e6551c3e8 (diff)
downloaddrakiso-ff30da3ebb107421372e2a1a6d37f7c189667f2b.tar
drakiso-ff30da3ebb107421372e2a1a6d37f7c189667f2b.tar.gz
drakiso-ff30da3ebb107421372e2a1a6d37f7c189667f2b.tar.bz2
drakiso-ff30da3ebb107421372e2a1a6d37f7c189667f2b.tar.xz
drakiso-ff30da3ebb107421372e2a1a6d37f7c189667f2b.zip
Simplify run_() helper function and minimise direct calls to system().
Diffstat (limited to 'draklive')
-rwxr-xr-xdraklive4
1 files changed, 2 insertions, 2 deletions
diff --git a/draklive b/draklive
index 046daac..e5cd63d 100755
--- a/draklive
+++ b/draklive
@@ -54,11 +54,11 @@ sub clean {
if (-e $build->get_build_dir) {
umount_all_in_root($build->get_build_dir);
- system('sudo rm -rf ' . $build->get_build_dir);
+ run_as_root('rm', '-rf', $build->get_build_dir);
}
if (-e $build->get_chroot_dir) {
umount_all_in_root($build->get_chroot_dir);
- system('sudo rm -rf ' . $build->get_chroot_dir);
+ run_as_root('rm', '-rf', $build->get_chroot_dir);
}
}