Displaying 1 result from an estimated 1 matches for "match_file".
Did you mean:
_match_file
2009 Jul 24
2
[PATCH] Initial drop of virt-v2v
...$augeas if(defined($augeas));
+ die("Unable to find augeas path similar to $path for $device");
+}
+
+sub add_kernel
+{
+ my $self = shift;
+ my $kernel_arch = "i386"; # XXX: Need to get this from inspection!
+
+ my $g = $self->{g};
+
+ my $filename = $self->match_file('kernel', $kernel_arch);
+
+ # Inspect the rpm to work out what kernel version it contains
+ my $version;
+ foreach my $file ($g->command_lines(["rpm", "-qlp", $filename])) {
+ if($file =~ m{^/boot/vmlinuz-(.*)$}) {
+ $version = $1;
+...