Select swap partition format automatically

This commit is contained in:
Manuel Thalmann 2024-06-22 20:06:01 +02:00
parent fa066d486c
commit 0ffc88451a

View file

@ -192,6 +192,10 @@
format = mkOption {
type = types.enum (builtins.attrValues fs);
description = "The file system format of the partition.";
default =
if (isSwap config)
then fs.swap
else throw("Partition format not specified.");
};
size = mkOption {
@ -254,7 +258,6 @@
Swap = {
index = 2;
type = "swap";
format = fs.ntfs;
};
OS = {