diff options
author | Pascal Rigaux <pixel@mandriva.com> | 2008-09-01 16:13:40 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 2008-09-01 16:13:40 +0000 |
commit | 73e9459062f85bca8adef6976df8d4a6f2dbbbe0 (patch) | |
tree | eabc1b7087d327714d1837a563fdaa75a137387a /perl-install/common.pm | |
parent | f9b8c020f93d96f52c734eba139e06b59d6a820f (diff) | |
download | drakx-73e9459062f85bca8adef6976df8d4a6f2dbbbe0.tar drakx-73e9459062f85bca8adef6976df8d4a6f2dbbbe0.tar.gz drakx-73e9459062f85bca8adef6976df8d4a6f2dbbbe0.tar.bz2 drakx-73e9459062f85bca8adef6976df8d4a6f2dbbbe0.tar.xz drakx-73e9459062f85bca8adef6976df8d4a6f2dbbbe0.zip |
- keep in $o->{previous_release} the info about upgraded /etc/release,
and pass "reason" and version to urpmi.addmedia
- we also parse {version} field out of /etc/release
Diffstat (limited to 'perl-install/common.pm')
-rw-r--r-- | perl-install/common.pm | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/perl-install/common.pm b/perl-install/common.pm index 2234c0e91..32854daed 100644 --- a/perl-install/common.pm +++ b/perl-install/common.pm @@ -312,9 +312,11 @@ sub is_running { sub parse_release_file { my ($prefix, $f, $part) = @_; chomp(my $s = cat_("$prefix$f")); + my $version = $s =~ s/\s+release\s+(\S+)// && $1; my $arch = $s =~ s/\s+for\s+(\S+)// && $1; log::l("find_root_parts found $part->{device}: $s for $arch" . ($f !~ m!/etc/! ? " in special release file $f" : '')); - { release => $s, release_file => $f, part => $part, arch => $arch }; + { release => $s, version => $version, + release_file => $f, part => $part, arch => $arch }; } sub release_file { |