From 9f29cedac79d0acf07b6341f9112f46dec3abb8f Mon Sep 17 00:00:00 2001 From: lassulus Date: Thu, 14 Sep 2023 17:06:31 +0200 Subject: [PATCH] rename makeDiskImage -> makeDiskImages --- lib/default.nix | 4 ++-- lib/types/disk.nix | 2 +- module.nix | 4 ++-- tests/make-disk-image-impure.nix | 2 +- tests/make-disk-image.nix | 2 +- 5 files changed, 7 insertions(+), 7 deletions(-) diff --git a/lib/default.nix b/lib/default.nix index 5d40d8c..598081c 100644 --- a/lib/default.nix +++ b/lib/default.nix @@ -11,10 +11,10 @@ let diskoLib = { # like make-disk-image.nix from nixpkgs, but with disko config - makeDiskImage = args: (import ./make-disk-image.nix ({ inherit diskoLib; } // args)).pure; + makeDiskImages = args: (import ./make-disk-image.nix ({ inherit diskoLib; } // args)).pure; # a version of makeDiskImage which runs outside of the store - makeDiskImageScript = args: (import ./make-disk-image.nix ({ inherit diskoLib; } // args)).impure; + makeDiskImagesScript = args: (import ./make-disk-image.nix ({ inherit diskoLib; } // args)).impure; testLib = import ./tests.nix { inherit lib makeTest eval-config; }; # like lib.types.oneOf but instead of a list takes an attrset diff --git a/lib/types/disk.nix b/lib/types/disk.nix index b6622c7..60f31b5 100644 --- a/lib/types/disk.nix +++ b/lib/types/disk.nix @@ -19,7 +19,7 @@ imageSize = lib.mkOption { type = lib.types.strMatching "[0-9]+[KMGTP]?"; description = '' - size of the image if the makeDiskImage function from diksoLib is used. + size of the image if the makeDiskImages function from diksoLib is used. is used as an argument to truncate -s ''; default = "2G"; diff --git a/module.nix b/module.nix index 7096cf6..fbbb7e8 100644 --- a/module.nix +++ b/module.nix @@ -71,10 +71,10 @@ in disko = builtins.trace "the .disko output is deprecated, please use .diskoScript instead" (cfg.devices._scripts pkgs).diskoScript; diskoNoDeps = builtins.trace "the .diskoNoDeps output is deprecated, please use .diskoScriptNoDeps instead" (cfg.devices._scripts pkgs).diskoScriptNoDeps; - diskoImages = diskoLib.makeDiskImage { + diskoImages = diskoLib.makeDiskImages { nixosConfig = args; }; - diskoImageScript = diskoLib.makeDiskImageScript { + diskoImagesScript = diskoLib.makeDiskImagesScript { nixosConfig = args; }; diff --git a/tests/make-disk-image-impure.nix b/tests/make-disk-image-impure.nix index 8814d0a..cdb8ed9 100644 --- a/tests/make-disk-image-impure.nix +++ b/tests/make-disk-image-impure.nix @@ -1,7 +1,7 @@ { pkgs ? import { } , diskoLib ? pkgs.callPackage ../lib { } }: -diskoLib.makeDiskImageScript { +diskoLib.makeDiskImagesScript { nixosConfig = pkgs.nixos [ ../module.nix ../example/simple-efi.nix diff --git a/tests/make-disk-image.nix b/tests/make-disk-image.nix index d8d15c1..15c1fc4 100644 --- a/tests/make-disk-image.nix +++ b/tests/make-disk-image.nix @@ -1,7 +1,7 @@ { pkgs ? import { } , diskoLib ? pkgs.callPackage ../lib { } }: -diskoLib.makeDiskImage { +diskoLib.makeDiskImages { nixosConfig = pkgs.nixos [ ../module.nix ../example/simple-efi.nix