Select swap partition format automatically
This commit is contained in:
parent
fa066d486c
commit
0ffc88451a
1 changed files with 4 additions and 1 deletions
|
@ -192,6 +192,10 @@
|
||||||
format = mkOption {
|
format = mkOption {
|
||||||
type = types.enum (builtins.attrValues fs);
|
type = types.enum (builtins.attrValues fs);
|
||||||
description = "The file system format of the partition.";
|
description = "The file system format of the partition.";
|
||||||
|
default =
|
||||||
|
if (isSwap config)
|
||||||
|
then fs.swap
|
||||||
|
else throw("Partition format not specified.");
|
||||||
};
|
};
|
||||||
|
|
||||||
size = mkOption {
|
size = mkOption {
|
||||||
|
@ -254,7 +258,6 @@
|
||||||
Swap = {
|
Swap = {
|
||||||
index = 2;
|
index = 2;
|
||||||
type = "swap";
|
type = "swap";
|
||||||
format = fs.ntfs;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
OS = {
|
OS = {
|
||||||
|
|
Loading…
Reference in a new issue