2017-07-03 11:07:10 +00:00
|
|
|
image: registry.gitlab.com/fdroid/ci-images-server:latest
|
2016-02-29 14:57:49 +00:00
|
|
|
|
2015-07-29 23:13:49 +00:00
|
|
|
before_script:
|
2016-02-26 16:37:50 +00:00
|
|
|
- rm -rf fdroidserver
|
2018-02-23 21:32:55 +00:00
|
|
|
- mkdir fdroidserver
|
|
|
|
- curl --silent https://gitlab.com/fdroid/fdroidserver/repository/master/archive.tar.gz
|
|
|
|
| tar -xz --directory=fdroidserver --strip-components=1
|
2015-09-02 04:23:28 +00:00
|
|
|
- export PATH="$PWD/fdroidserver:$PATH"
|
2015-07-30 19:36:17 +00:00
|
|
|
- touch config.py
|
2015-07-29 23:13:49 +00:00
|
|
|
|
2015-09-12 01:16:14 +00:00
|
|
|
lint:
|
2015-07-29 23:41:37 +00:00
|
|
|
script:
|
2018-01-22 10:56:28 +00:00
|
|
|
# if this is a merge request fork, then only check relevant apps
|
|
|
|
- if [ "$CI_PROJECT_NAMESPACE" != "fdroid" ]; then
|
|
|
|
git fetch https://gitlab.com/fdroid/fdroiddata;
|
|
|
|
test -d build || mkdir build;
|
2018-03-12 12:32:39 +00:00
|
|
|
for f in `git diff --name-only --diff-filter=d FETCH_HEAD...HEAD`; do
|
2018-02-23 21:28:53 +00:00
|
|
|
appid=`echo $f | sed -n -e 's,^metadata/\([^/][^/]*\)\.txt,\1,p'
|
|
|
|
-e 's,^metadata/\([^/][^/]*\)\.yml,\1,p'`;
|
2018-01-22 10:56:28 +00:00
|
|
|
export CHANGED="$CHANGED $appid";
|
|
|
|
grep -q "^Repo *Type\W *git" $f && git -C build clone `sed -n "s,^Repo *:,,p" $f` $appid;
|
|
|
|
done;
|
2018-01-22 11:07:11 +00:00
|
|
|
./tools/audit-gradle.py $CHANGED;
|
2018-01-22 10:56:28 +00:00
|
|
|
fi
|
2017-01-26 13:28:00 +00:00
|
|
|
- export EXITVALUE=0
|
2018-01-22 10:56:28 +00:00
|
|
|
- fdroid lint -f $CHANGED || {
|
2017-01-26 13:28:00 +00:00
|
|
|
export EXITVALUE=1;
|
|
|
|
printf "\nThese files have lint issues:\n";
|
2018-01-22 10:56:28 +00:00
|
|
|
fdroid rewritemeta -l $CHANGED;
|
2017-01-26 13:28:00 +00:00
|
|
|
printf "\nThese are the formatting issues:\n";
|
2018-01-22 10:56:28 +00:00
|
|
|
fdroid rewritemeta $CHANGED;
|
2017-01-26 13:28:00 +00:00
|
|
|
git --no-pager diff --color=always;
|
|
|
|
}
|
2018-03-07 22:50:03 +00:00
|
|
|
- apt-get -qy update
|
|
|
|
- apt-get -qy install --no-install-recommends exiftool
|
|
|
|
- exiftool -all= `find metadata/ -name '*.jp*g' -o -name '*.png'`
|
|
|
|
- echo "these images have EXIF that must be stripped:"
|
|
|
|
- git --no-pager diff --stat
|
|
|
|
- git --no-pager diff --name-only --exit-code || export EXITVALUE=1
|
2017-01-26 13:28:00 +00:00
|
|
|
- exit $EXITVALUE
|