summaryrefslogtreecommitdiffstats
path: root/perl-install
diff options
context:
space:
mode:
Diffstat (limited to 'perl-install')
-rw-r--r--perl-install/NEWS1
-rw-r--r--perl-install/bootloader.pm3
2 files changed, 4 insertions, 0 deletions
diff --git a/perl-install/NEWS b/perl-install/NEWS
index d876d8d50..e87ebcf4e 100644
--- a/perl-install/NEWS
+++ b/perl-install/NEWS
@@ -1,4 +1,5 @@
- drakboot:
+ o add basic support for reading back grub2 config
o read & write /boot/grub2/drakboot.conf
o prevent installing grub2 somewhere else than MBR
- always bypass blkid cache (the cache only includes a subset of the data we need)
diff --git a/perl-install/bootloader.pm b/perl-install/bootloader.pm
index 9e8a7d66a..68df8acd3 100644
--- a/perl-install/bootloader.pm
+++ b/perl-install/bootloader.pm
@@ -235,6 +235,9 @@ sub read {
sub read_grub2 {
my %bootloader = getVarsFromSh("$::prefix/boot/grub2/drakboot.conf");
+ $bootloader{entries} = [ map { if_(/menuentry\s+['"]([^']+)["']/, { label => $1 }) } cat_("$::prefix/boot/grub2/grub.cfg") ];
+ $bootloader{method} = 'grub2';
+ \%bootloader;
}
sub read_grub {