about summary refs log tree commit diff
path: root/nixos
diff options
context:
space:
mode:
authorDomen Kožar <domen@dev.si>2016-09-01 10:13:47 +0200
committerDomen Kožar <domen@dev.si>2016-09-01 10:14:44 +0200
commit5e5b0d039c7052b563a498608cd90e6184603504 (patch)
tree440e0562afd9676cc4ff324d4a82b2e7dfc22250 /nixos
parent85546fb342d857e82f2d97b2ac17a102a759d403 (diff)
downloadnixlib-5e5b0d039c7052b563a498608cd90e6184603504.tar
nixlib-5e5b0d039c7052b563a498608cd90e6184603504.tar.gz
nixlib-5e5b0d039c7052b563a498608cd90e6184603504.tar.bz2
nixlib-5e5b0d039c7052b563a498608cd90e6184603504.tar.lz
nixlib-5e5b0d039c7052b563a498608cd90e6184603504.tar.xz
nixlib-5e5b0d039c7052b563a498608cd90e6184603504.tar.zst
nixlib-5e5b0d039c7052b563a498608cd90e6184603504.zip
install-grub.pl: add comments
Diffstat (limited to 'nixos')
-rw-r--r--nixos/modules/system/boot/loader/grub/install-grub.pl4
1 files changed, 4 insertions, 0 deletions
diff --git a/nixos/modules/system/boot/loader/grub/install-grub.pl b/nixos/modules/system/boot/loader/grub/install-grub.pl
index 4fa157641a4a..4110335a9eb8 100644
--- a/nixos/modules/system/boot/loader/grub/install-grub.pl
+++ b/nixos/modules/system/boot/loader/grub/install-grub.pl
@@ -12,8 +12,10 @@ require List::Compare;
 use POSIX;
 use Cwd;
 
+# system.build.toplevel path
 my $defaultConfig = $ARGV[1] or die;
 
+# Grub config XML generated by grubConfig function in grub.nix
 my $dom = XML::LibXML->load_xml(location => $ARGV[0]);
 
 sub get { my ($name) = @_; return $dom->findvalue("/expr/attrs/attr[\@name = '$name']/*/\@value"); }
@@ -97,6 +99,8 @@ sub PathInMount {
     }
     return 1;
 }
+
+# Figure out what filesystem is used for the directory with init/initrd/kernel files
 sub GetFs {
     my ($dir) = @_;
     my $bestFs = Fs->new(device => "", type => "", mount => "");