diff --git a/nixos/modules/installer/tools/nixos-generate-config.pl b/nixos/modules/installer/tools/nixos-generate-config.pl index ab5b2954f6b5..c6f499b82506 100644 --- a/nixos/modules/installer/tools/nixos-generate-config.pl +++ b/nixos/modules/installer/tools/nixos-generate-config.pl @@ -22,7 +22,7 @@ sub uniq { sub runCommand { my ($cmd) = @_; - open FILE, "$cmd 2>/dev/null |" or die "Failed to execute: $cmd\n"; + open FILE, "$cmd 2>&1 |" or die "Failed to execute: $cmd\n"; my @ret = ; close FILE; return ($?, @ret); @@ -311,10 +311,13 @@ foreach my $fs (read_file("/proc/self/mountinfo")) { # Maybe this is a bind-mount of a filesystem we saw earlier? if (defined $fsByDev{$fields[2]}) { - my $path = $fields[3]; $path = "" if $path eq "/"; - my $base = $fsByDev{$fields[2]}; - $base = "" if $base eq "/"; - $fileSystems .= <