gitlat-ci: fix detection of appids changed in this merge request

It was detecting changed description files in subfolders, i.e.:
metadata/org.fdroid.fdroid.ota/en-US/description.txt
metadata/org.fdroid.fdroid.ota/en-US/summary.txt
This commit is contained in:
Hans-Christoph Steiner 2018-02-23 22:28:53 +01:00
parent 23a62fd5fa
commit 38d0e8cd39

View file

@ -15,8 +15,8 @@ lint:
git fetch https://gitlab.com/fdroid/fdroiddata;
test -d build || mkdir build;
for f in `git diff --name-only FETCH_HEAD`; do
appid=`echo $f | sed -n -e 's,^metadata/\(.*\)\.txt,\1,p'
-e 's,^metadata/\(.*\)\.yml,\1,p'`;
appid=`echo $f | sed -n -e 's,^metadata/\([^/][^/]*\)\.txt,\1,p'
-e 's,^metadata/\([^/][^/]*\)\.yml,\1,p'`;
export CHANGED="$CHANGED $appid";
grep -q "^Repo *Type\W *git" $f && git -C build clone `sed -n "s,^Repo *:,,p" $f` $appid;
done;