From 86d01dec19bddf8365e19a34d8597b4fd8137722 Mon Sep 17 00:00:00 2001 From: Peder Bergebakken Sundt Date: Mon, 9 Jun 2025 02:57:52 +0200 Subject: [PATCH] nice --- justfile | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/justfile b/justfile index f798999..c51bae7 100644 --- a/justfile +++ b/justfile @@ -254,7 +254,7 @@ _instantiate_packages $system +$attrpaths: if [[ -s "$_JUST_NIX_INSTANTIATE_CACHE/paths/$attrpath.drv" ]]; then cat "$_JUST_NIX_INSTANTIATE_CACHE/paths/$attrpath.drv" else - NIXPKGS_ALLOW_UNFREE=1 nix-instantiate . -A "$attrpath" \ + NIXPKGS_ALLOW_UNFREE=1 nice -n5 nix-instantiate . -A "$attrpath" \ --system "$system" \ ${_JUST_NIX_INSTANTIATE_ARGS:-} \ --add-root "$_JUST_NIX_INSTANTIATE_CACHE/roots/$attrpath.drv" \ @@ -336,7 +336,7 @@ __build_packages $system $outdir +$attrpaths: # NIXPKGS_ALLOW_UNFREE=1 nix-build "$drvpath" -j0 --option builders "" --option substitute false --out-link "$dst" >&/dev/null # NIXPKGS_ALLOW_UNFREE=1 nix-build "$drvpath" -j0 --option builders "" --option substitute false --out-link "$gcroot" >&/dev/null #nix-build "$drvpath" -j0 --option builders "" --option substitute false --out-link "$gcroot" >&/dev/null ||: - nix-build "$inStoreDrvPath" -j0 --option builders "" --option substitute false --out-link "$gcroot" >&/dev/null ||: + nice -n5 nix-build "$inStoreDrvPath" -j0 --option builders "" --option substitute false --out-link "$gcroot" >&/dev/null ||: if [[ "$drvpath" =~ '!' ]]; then # :( gcroot="$gcroot-$(cut -d! -f2 <<<"$drvpath")" @@ -347,14 +347,14 @@ __build_packages $system $outdir +$attrpaths: fi # local outpaths=$( nix-store -q --outputs "$drvpath" ) # doesn't gcroot, some outputs may not be pulled from builders if [[ -L "$dst" ]]; then - nix log $(readlink "$dst") > "$dst".log 2>/dev/null ||: - # nix log --option substituters "" $(readlink "$dst") > "$dst".log 2>/dev/null ||: + nice -n5 nix log $(readlink "$dst") > "$dst".log 2>/dev/null ||: + # nice -n5 nix log --option substituters "" $(readlink "$dst") > "$dst".log 2>/dev/null ||: else if [[ -z "$drvpath" ]]; then ln -s "$NOTFOUNDDIR"/no-eval "$dst" else ln -s /build-failure-"$attrpath" "$dst" - nix log --option substituters "" ".#$attrpath" --system "$system" ${_JUST_NIX_INSTANTIATE_ARGS:-} > "$dst".log 2>/dev/null ||: + nice -n5 nix log --option substituters "" ".#$attrpath" --system "$system" ${_JUST_NIX_INSTANTIATE_ARGS:-} > "$dst".log 2>/dev/null ||: fi fi }