forked from colin/nix-files
nit: fix image output to be a file, not an item inside a folder
This commit is contained in:
parent
56d84dea4d
commit
aa0a395353
|
@ -279,7 +279,7 @@ in
|
|||
sane.image.extraGPTPadding = 16 * 1024 * 1024;
|
||||
sane.image.firstPartGap = 0;
|
||||
sane.image.installBootloader = ''
|
||||
dd if=${pkgs.tow-boot-pinephone}/Tow-Boot.noenv.bin of=$out/nixos.img bs=1024 seek=8 conv=notrunc
|
||||
dd if=${pkgs.tow-boot-pinephone}/Tow-Boot.noenv.bin of=$out bs=1024 seek=8 conv=notrunc
|
||||
'';
|
||||
|
||||
sane.programs.swaynotificationcenter.config = {
|
||||
|
|
|
@ -173,17 +173,20 @@ in
|
|||
in
|
||||
lib.mkIf cfg.enable
|
||||
{
|
||||
system.build.img = (if cfg.installBootloader == null then
|
||||
img
|
||||
else pkgs.runCommand "nixos-with-bootloader" {} ''
|
||||
cp -vR ${img} $out
|
||||
chmod -R +w $out
|
||||
${cfg.installBootloader}
|
||||
'') // {
|
||||
system.build.img = pkgs.runCommandLocal "nixos-with-bootloader" {
|
||||
passthru = {
|
||||
inherit bootFsImg nixFsImg;
|
||||
withoutBootloader = img;
|
||||
withoutBootloader = img; #< XXX: this derivation places the image at $out/nixos.img
|
||||
};
|
||||
};
|
||||
} (
|
||||
if cfg.installBootloader == null then ''
|
||||
ln -s ${img}/nixos.img $out
|
||||
'' else ''
|
||||
cp ${img}/nixos.img $out
|
||||
chmod +w $out
|
||||
${cfg.installBootloader}
|
||||
chmod -w $out
|
||||
''
|
||||
);
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user