From 3eef61a6eb4f1f53491c94dfcb0413ef3d71c129 Mon Sep 17 00:00:00 2001 From: "Nicolas B. Pierron" Date: Wed, 8 Apr 2015 23:10:42 +0200 Subject: [PATCH 1/2] NixOS Manual: Do not use unfree packages as default value. --- nixos/modules/services/networking/btsync.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/nixos/modules/services/networking/btsync.nix b/nixos/modules/services/networking/btsync.nix index 0bfd3b74348..8b90f295ed4 100644 --- a/nixos/modules/services/networking/btsync.nix +++ b/nixos/modules/services/networking/btsync.nix @@ -200,7 +200,6 @@ in package = mkOption { type = types.package; - default = pkgs.bittorrentSync14; example = literalExample "pkgs.bittorrentSync20"; description = '' Branch of bittorrent sync to use. @@ -277,6 +276,8 @@ in } ]; + services.btsync.package = mkOptionDefault pkgs.bittorrentSync14; + users.extraUsers.btsync = { description = "Bittorrent Sync Service user"; home = cfg.storagePath; From 296e6c499199b32315c071654b3dee7f40adb1a4 Mon Sep 17 00:00:00 2001 From: "Nicolas B. Pierron" Date: Wed, 8 Apr 2015 23:12:11 +0200 Subject: [PATCH 2/2] Fix #7252 - NixOS Manual: Carry the current system value to evaluation of the manual. --- nixos/modules/misc/nixpkgs.nix | 4 ++-- nixos/modules/services/misc/nixos-manual.nix | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/nixos/modules/misc/nixpkgs.nix b/nixos/modules/misc/nixpkgs.nix index 395ba82f2d1..114feb2562d 100644 --- a/nixos/modules/misc/nixpkgs.nix +++ b/nixos/modules/misc/nixpkgs.nix @@ -59,8 +59,8 @@ in }; nixpkgs.system = mkOption { - type = types.str; - default = builtins.currentSystem; + type = types.uniq types.str; + example = "i686-linux"; description = '' Specifies the Nix platform type for which NixOS should be built. If unset, it defaults to the platform type of your host system. diff --git a/nixos/modules/services/misc/nixos-manual.nix b/nixos/modules/services/misc/nixos-manual.nix index f73c4102cfe..c570a01fb3b 100644 --- a/nixos/modules/services/misc/nixos-manual.nix +++ b/nixos/modules/services/misc/nixos-manual.nix @@ -14,6 +14,7 @@ let versionModule = { system.nixosVersionSuffix = config.system.nixosVersionSuffix; system.nixosRevision = config.system.nixosRevision; + nixpkgs.system = config.nixpkgs.system; }; eval = evalModules {