From 07ed3c88e045d84ab282272c9f1b675c15487ba1 Mon Sep 17 00:00:00 2001 From: Erich Eckner Date: Tue, 13 Feb 2018 11:20:08 +0100 Subject: bin/sanity-check: check full name of package in database --- bin/sanity-check | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) (limited to 'bin/sanity-check') diff --git a/bin/sanity-check b/bin/sanity-check index e31a5ba..39a2d10 100755 --- a/bin/sanity-check +++ b/bin/sanity-check @@ -270,17 +270,18 @@ while [ $# -gt 0 ]; do errors=$( { - tar -tzf "${tmp_dir}/${repo}.db.tar.gz" | \ - grep '/$' | \ - sed ' - s|/$|| - s|^|in_database | + tar -Oxzf "${tmp_dir}/${repo}.db.tar.gz" --wildcards '*/desc' 2>/dev/null | \ + sed -n ' + /^%FILENAME%$/ { + N + s/^.*\n/in_database / + p + } ' echo "${packages}" | \ - grep '\S' | \ sed ' - s|-[^-]\+$|| - s|^|in_repository | + /\.pkg\.tar\.xz$/ !d + s/^/in_repository / ' | \ sort -u } | \ -- cgit v1.2.3-70-g09d2