summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOlivier Blin <oblin@mandriva.com>2009-10-08 14:14:21 +0000
committerOlivier Blin <oblin@mandriva.com>2009-10-08 14:14:21 +0000
commitefcbeaf463fdb27d41e0993952d0ecd76e06bca1 (patch)
treefc7bd4ed9aa13f44564dd8715a6ec94806897157
parent56354459b74edcf7f3eb4a10ff37967ee68aa2cb (diff)
downloaddraklive-efcbeaf463fdb27d41e0993952d0ecd76e06bca1.tar
draklive-efcbeaf463fdb27d41e0993952d0ecd76e06bca1.tar.gz
draklive-efcbeaf463fdb27d41e0993952d0ecd76e06bca1.tar.bz2
draklive-efcbeaf463fdb27d41e0993952d0ecd76e06bca1.tar.xz
draklive-efcbeaf463fdb27d41e0993952d0ecd76e06bca1.zip
simplify
-rwxr-xr-xdraklive20
1 files changed, 10 insertions, 10 deletions
diff --git a/draklive b/draklive
index c2ec0c2..6347795 100755
--- a/draklive
+++ b/draklive
@@ -339,24 +339,24 @@ sub post_install_system {
sub write_dist_lists {
my ($live) = @_;
- my $lst = $live->get_builddir . $live->{prefix}{build}{dist} . '/' . $live->get_name . '.lst';
- mkdir_p(dirname($lst));
- run_("chroot " . $live->get_system_root . " rpm -qa | sort > " . $lst);
+ my $lists_dir = $live->get_builddir . $live->{prefix}{build}{dist};
+ mkdir_p($lists_dir);
+
+ run_("chroot " . $live->get_system_root . " rpm -qa | sort > " .
+ $lists_dir . '/' . $live->get_name . '.lst');
- my $full = $live->get_builddir . $live->{prefix}{build}{dist} . '/' . $live->get_name . '.lst.full';
- mkdir_p(dirname($full));
run_("chroot " . $live->get_system_root .
- qq( sh -c "rpm -qa --qf '%{size} \t%{name}\n' | sort -n" > ) . $full);
+ qq( sh -c "rpm -qa --qf '%{size} \t%{name}\n' | sort -n" > ) .
+ $lists_dir . '/' . $live->get_name . '.lst.full');
- my $leaves = $live->get_builddir . $live->{prefix}{build}{dist} . '/' . $live->get_name . '.lst.leaves';
- mkdir_p(dirname($leaves));
run_("chroot " . $live->get_system_root .
- qq( sh -c "urpmi_rpm-find-leaves | xargs rpm -q --qf '%{size} \t%{name}\n' | sort -n" > ) . $leaves);
+ qq( sh -c "urpmi_rpm-find-leaves | xargs rpm -q --qf '%{size} \t%{name}\n' | sort -n" > ) .
+ $lists_dir . '/' . $live->get_name . '.lst.leaves');
require lang;
my @live_langs = get_langs($live);
my @langs = grep { member(lang::locale_to_main_locale($_), @live_langs) } lang::list_langs();
- my $langs_file = $live->get_builddir . $live->{prefix}{build}{dist} . '/' . $live->get_name . '.langs';
+ my $langs_file = $lists_dir . '/' . $live->get_name . '.langs';
output_p($langs_file, map { lang::l2name($_) . " (" . $_ . ")\n" } sort(@langs));
}