forked from mirrors/nixpkgs
* Clean up the nixos-rebuild output a bit.
svn path=/nixos/trunk/; revision=18859
This commit is contained in:
parent
e0d69c92a8
commit
f26080c5f4
|
@ -132,8 +132,9 @@ fi
|
||||||
# current one. Of course, the same goes for Nixpkgs, but Nixpkgs is
|
# current one. Of course, the same goes for Nixpkgs, but Nixpkgs is
|
||||||
# more conservative.
|
# more conservative.
|
||||||
if test -n "$buildNix"; then
|
if test -n "$buildNix"; then
|
||||||
if ! nix-build $NIXOS -A nixFallback -o $tmpDir/nix; then
|
echo "building Nix..." >&2
|
||||||
nix-build $NIXPKGS -A nixUnstable -o $tmpDir/nix
|
if ! nix-build $NIXOS -A nixFallback -o $tmpDir/nix > /dev/null; then
|
||||||
|
nix-build $NIXPKGS -A nixUnstable -o $tmpDir/nix > /dev/null
|
||||||
fi
|
fi
|
||||||
PATH=$tmpDir/nix/bin:$PATH
|
PATH=$tmpDir/nix/bin:$PATH
|
||||||
fi
|
fi
|
||||||
|
@ -143,14 +144,15 @@ fi
|
||||||
# or "boot"), or just build it and create a symlink "result" in the
|
# or "boot"), or just build it and create a symlink "result" in the
|
||||||
# current directory (for "build" and "test").
|
# current directory (for "build" and "test").
|
||||||
if test -z "$rollback"; then
|
if test -z "$rollback"; then
|
||||||
|
echo "building the system configuration..." >&2
|
||||||
if test "$action" = switch -o "$action" = boot; then
|
if test "$action" = switch -o "$action" = boot; then
|
||||||
nix-env -p /nix/var/nix/profiles/system -f $NIXOS --set -A system $extraBuildFlags
|
nix-env -p /nix/var/nix/profiles/system -f $NIXOS --set -A system $extraBuildFlags
|
||||||
pathToConfig=/nix/var/nix/profiles/system
|
pathToConfig=/nix/var/nix/profiles/system
|
||||||
elif test "$action" = test -o "$action" = build -o "$action" = dry-run; then
|
elif test "$action" = test -o "$action" = build -o "$action" = dry-run; then
|
||||||
nix-build $NIXOS -A system -K -k $extraBuildFlags
|
nix-build $NIXOS -A system -K -k $extraBuildFlags > /dev/null
|
||||||
pathToConfig=./result
|
pathToConfig=./result
|
||||||
elif test "$action" = build-vm; then
|
elif test "$action" = build-vm; then
|
||||||
nix-build $NIXOS -A vm -K -k $extraBuildFlags
|
nix-build $NIXOS -A vm -K -k $extraBuildFlags > /dev/null
|
||||||
pathToConfig=./result
|
pathToConfig=./result
|
||||||
else
|
else
|
||||||
showSyntax
|
showSyntax
|
||||||
|
|
|
@ -57,9 +57,6 @@ EOF
|
||||||
oldJobs=$(readlink -f /etc/static/init)
|
oldJobs=$(readlink -f /etc/static/init)
|
||||||
newJobs=$(readlink -f @out@/etc/init)
|
newJobs=$(readlink -f @out@/etc/init)
|
||||||
|
|
||||||
echo "old: $oldJobs"
|
|
||||||
echo "new: $newJobs"
|
|
||||||
|
|
||||||
stopJob() {
|
stopJob() {
|
||||||
local job=$1
|
local job=$1
|
||||||
initctl stop "$job" || true
|
initctl stop "$job" || true
|
||||||
|
|
Loading…
Reference in a new issue