From b0b4c0e2b3622494c9ddbe1bc6cc99e17ba90885 Mon Sep 17 00:00:00 2001 From: Marc Weber Date: Tue, 26 Aug 2008 19:44:54 +0000 Subject: [PATCH] echo working copies beeing used when calling showSyntax (help output) svn path=/nixos/trunk/; revision=12729 --- installer/nixos-rebuild.sh | 19 ++++++++++++------- 1 file changed, 12 insertions(+), 7 deletions(-) diff --git a/installer/nixos-rebuild.sh b/installer/nixos-rebuild.sh index c173787d585..80ed41c7d95 100644 --- a/installer/nixos-rebuild.sh +++ b/installer/nixos-rebuild.sh @@ -1,5 +1,10 @@ #! @shell@ -e +# Allow the location of NixOS sources and the system configuration +# file to be overridden. +NIXOS=${NIXOS:-@defaultNIXOS@} +NIXPKGS=${NIXPKGS:-@defaultNIXPKGS@} +NIXOS_CONFIG=${NIXOS_CONFIG:-/etc/nixos/configuration.nix} showSyntax() { # !!! more or less cut&paste from @@ -13,6 +18,13 @@ test: activate the configuration, but don't make it the boot default build: build the configuration, but don't make it the default or activate it dry-run: just show what store paths would be built/downloaded + +by env overridable settings: +NIXOS=${NIXOS} +NIXPKGS=${NIXPKGS} +NIXOS_CONFIG=${NIXOS_CONFIG} +" + EOF exit 1 } @@ -40,13 +52,6 @@ if test "$action" = dry-run; then fi -# Allow the location of NixOS sources and the system configuration -# file to be overridden. -NIXOS=${NIXOS:-@defaultNIXOS@} -NIXPKGS=${NIXPKGS:-@defaultNIXPKGS@} -NIXOS_CONFIG=${NIXOS_CONFIG:-/etc/nixos/configuration.nix} - - # If the Nix daemon is running, then use it. This allows us to use # the latest Nix from Nixpkgs (below) for expression evaluation, while # still using the old Nix (via the daemon) for actual store access.