summary refs log tree commit diff
diff options
context:
space:
mode:
authorNicolas Pierron <nicolas.b.pierron@gmail.com>2010-09-03 19:10:54 +0000
committerNicolas Pierron <nicolas.b.pierron@gmail.com>2010-09-03 19:10:54 +0000
commit1f69bc4b9d295d677ea332fb41d7ffe86c849ee7 (patch)
tree8a5fde6cde0869b6ce5f85912940ce2b3853a84a
parent9e04f67b3d7f1b2870dc38329692645bdd645534 (diff)
downloadnixpkgs-1f69bc4b9d295d677ea332fb41d7ffe86c849ee7.tar
nixpkgs-1f69bc4b9d295d677ea332fb41d7ffe86c849ee7.tar.gz
nixpkgs-1f69bc4b9d295d677ea332fb41d7ffe86c849ee7.tar.bz2
nixpkgs-1f69bc4b9d295d677ea332fb41d7ffe86c849ee7.tar.lz
nixpkgs-1f69bc4b9d295d677ea332fb41d7ffe86c849ee7.tar.xz
nixpkgs-1f69bc4b9d295d677ea332fb41d7ffe86c849ee7.tar.zst
nixpkgs-1f69bc4b9d295d677ea332fb41d7ffe86c849ee7.zip
Remove deprecated notation in tools.nix.
svn path=/nixos/trunk/; revision=23630
-rw-r--r--modules/installer/tools/tools.nix82
1 files changed, 39 insertions, 43 deletions
diff --git a/modules/installer/tools/tools.nix b/modules/installer/tools/tools.nix
index 9785cfe0db5..d9ebb58a9f8 100644
--- a/modules/installer/tools/tools.nix
+++ b/modules/installer/tools/tools.nix
@@ -4,35 +4,6 @@
 {config, pkgs, ...}:
 
 let
-
-  ### interface
-
-  options = {
-  
-    installer.nixpkgsURL = pkgs.lib.mkOption {
-      default = "";
-      example = http://nixos.org/releases/nix/nixpkgs-0.11pre7577;
-      description = ''
-        URL of the Nixpkgs distribution to use when building the
-        installation CD.
-      '';
-    };
-
-    installer.manifests = pkgs.lib.mkOption {
-      default = [http://nixos.org/releases/nixpkgs/channels/nixpkgs-unstable/MANIFEST];
-      example =
-        [ http://nixos.org/releases/nixpkgs/channels/nixpkgs-unstable/MANIFEST
-          http://nixos.org/releases/nixpkgs/channels/nixpkgs-stable/MANIFEST
-        ];
-      description = ''
-        URLs of manifests to be downloaded when you run
-        <command>nixos-rebuild</command> to speed up builds.
-      '';
-    };
-    
-  };
-
-
   ### implementation
 
   makeProg = args: pkgs.substituteAll (args // {
@@ -119,23 +90,48 @@ let
 in
 
 {
-  require = options;
+  options = {
+  
+    installer.nixpkgsURL = pkgs.lib.mkOption {
+      default = "";
+      example = http://nixos.org/releases/nix/nixpkgs-0.11pre7577;
+      description = ''
+        URL of the Nixpkgs distribution to use when building the
+        installation CD.
+      '';
+    };
+
+    installer.manifests = pkgs.lib.mkOption {
+      default = [http://nixos.org/releases/nixpkgs/channels/nixpkgs-unstable/MANIFEST];
+      example =
+        [ http://nixos.org/releases/nixpkgs/channels/nixpkgs-unstable/MANIFEST
+          http://nixos.org/releases/nixpkgs/channels/nixpkgs-stable/MANIFEST
+        ];
+      description = ''
+        URLs of manifests to be downloaded when you run
+        <command>nixos-rebuild</command> to speed up builds.
+      '';
+    };
+    
+  };
 
-  environment.systemPackages =
-    [ nixosInstall
-      nixosRebuild
-      nixosHardwareScan
-      nixosGenSeccureKeys
-      nixosOption
+  config = {
+    environment.systemPackages =
+      [ nixosInstall
+        nixosRebuild
+         nixosHardwareScan
+         nixosGenSeccureKeys
+         nixosOption
 
-      installer2.runInChroot
-      installer2.nixosPrepareInstall
-    ];
+         installer2.runInChroot
+         installer2.nixosPrepareInstall
+      ];
 
-  system.build = {
-    inherit nixosInstall;
+    system.build = {
+      inherit nixosInstall;
 
-    # expose scripts
-    inherit (installer2) nixosPrepareInstall runInChroot nixosBootstrap minimalInstallArchive;
+      # expose scripts
+      inherit (installer2) nixosPrepareInstall runInChroot nixosBootstrap minimalInstallArchive;
+    };
   };
 }