diff mbox series

[v3,06/12] support/scripts/pkg-stats: add package count to stats

Message ID 20200222085715.23769-7-heiko.thiery@gmail.com
State Superseded
Headers show
Series pkg-stats json output improvements | expand

Commit Message

Heiko Thiery Feb. 22, 2020, 8:57 a.m. UTC
Signed-off-by: Heiko Thiery <heiko.thiery@gmail.com>
---
 support/scripts/pkg-stats | 1 +
 1 file changed, 1 insertion(+)

Comments

Titouan Christophe Feb. 23, 2020, 2:40 p.m. UTC | #1
Heiko, all,

On 2/22/20 9:57 AM, Heiko Thiery wrote:
> Signed-off-by: Heiko Thiery <heiko.thiery@gmail.

Reviewed-by: Titouan Christophe <titouan.christophe@railnova.eu>
Tested-by: Titouan Christophe <titouan.christophe@railnova.eu>

> ---
>   support/scripts/pkg-stats | 1 +
>   1 file changed, 1 insertion(+)
> 
> diff --git a/support/scripts/pkg-stats b/support/scripts/pkg-stats
> index 7c8cc81cf2..90afcc2332 100755
> --- a/support/scripts/pkg-stats
> +++ b/support/scripts/pkg-stats
> @@ -544,6 +544,7 @@ def check_package_cves(nvd_path, packages):
>   
>   def calculate_stats(packages):
>       stats = defaultdict(int)
> +    stats['packages'] = len(packages)
>       for pkg in packages:
>           # If packages have multiple infra, take the first one. For the
>           # vast majority of packages, the target and host infra are the
>
diff mbox series

Patch

diff --git a/support/scripts/pkg-stats b/support/scripts/pkg-stats
index 7c8cc81cf2..90afcc2332 100755
--- a/support/scripts/pkg-stats
+++ b/support/scripts/pkg-stats
@@ -544,6 +544,7 @@  def check_package_cves(nvd_path, packages):
 
 def calculate_stats(packages):
     stats = defaultdict(int)
+    stats['packages'] = len(packages)
     for pkg in packages:
         # If packages have multiple infra, take the first one. For the
         # vast majority of packages, the target and host infra are the