summary refs log tree commit diff
path: root/pkgs/top-level
diff options
context:
space:
mode:
authorVladimír Čunát <vcunat@gmail.com>2019-03-01 13:59:30 +0100
committerVladimír Čunát <vcunat@gmail.com>2019-03-01 13:59:30 +0100
commita593f64cd7404666ac8364486773452cefa9baa9 (patch)
tree90a6ead53686eb00efc360f06235d4bfb3968504 /pkgs/top-level
parent36aa5b691d50f156244647415596327f7646e2dc (diff)
downloadnixpkgs-a593f64cd7404666ac8364486773452cefa9baa9.tar
nixpkgs-a593f64cd7404666ac8364486773452cefa9baa9.tar.gz
nixpkgs-a593f64cd7404666ac8364486773452cefa9baa9.tar.bz2
nixpkgs-a593f64cd7404666ac8364486773452cefa9baa9.tar.lz
nixpkgs-a593f64cd7404666ac8364486773452cefa9baa9.tar.xz
nixpkgs-a593f64cd7404666ac8364486773452cefa9baa9.tar.zst
nixpkgs-a593f64cd7404666ac8364486773452cefa9baa9.zip
metrics.nix: track qaCountBroken instead of qaCountDrv
From these three values, I believe it's most meaningful to track
one of the higher ones and their difference (qaCountBroken).
It's a bit unclear which of the higher ones - I have no data on that,
so I kept the one used before the parent commit.
Diffstat (limited to 'pkgs/top-level')
-rw-r--r--pkgs/top-level/metrics.nix7
1 files changed, 4 insertions, 3 deletions
diff --git a/pkgs/top-level/metrics.nix b/pkgs/top-level/metrics.nix
index d9cf985e41f..e60f42e14e2 100644
--- a/pkgs/top-level/metrics.nix
+++ b/pkgs/top-level/metrics.nix
@@ -52,11 +52,12 @@ runCommand "nixpkgs-metrics"
     run nix-env.qa nix-env -f ${nixpkgs} -qa
     run nix-env.qaDrv nix-env -f ${nixpkgs} -qa --drv-path --meta --xml
 
+    # It's slightly unclear which of the set to track: qaCount, qaCountDrv, qaCountBroken.
     num=$(nix-env -f ${nixpkgs} -qa | wc -l)
     echo "nix-env.qaCount $num" >> $out/nix-support/hydra-metrics
-
-    num=$(nix-env -f ${nixpkgs} -qa --drv-path | wc -l)
-    echo "nix-env.qaCountDrv $num" >> $out/nix-support/hydra-metrics
+    qaCountDrv=$(nix-env -f ${nixpkgs} -qa --drv-path | wc -l)
+    num=$((num - $qaCountDrv))
+    echo "nix-env.qaCountBroken $num" >> $out/nix-support/hydra-metrics
 
     # TODO: this has been ignored for some time
     # GC Warning: Bad initial heap size 128k - ignoring it.