fdroiddata/.gitlab-ci.yml
Hans-Christoph Steiner 92b09c7ef7 gitlab-ci: show diff when there are lint failures
Oftentimes, the lint failures are just simple whitespace issues.  Many
people submitting metadata do not really know much about the fdroid tools,
so they have to look up or ask what rewritemeta is.  This just shows a diff
after running rewritemeta so it should be clearer what the issue is.
2017-01-26 14:28:11 +01:00

21 lines
548 B
YAML

image: fdroid/ci:base-20161223
before_script:
- rm -rf fdroidserver
- git clone --depth=1 https://gitlab.com/fdroid/fdroidserver.git
- export PATH="$PWD/fdroidserver:$PATH"
- touch config.py
lint:
script:
- export EXITVALUE=0
- fdroid lint -f || {
export EXITVALUE=1;
printf "\nThese files have lint issues:\n";
fdroid rewritemeta -l;
printf "\nThese are the formatting issues:\n";
fdroid rewritemeta;
git --no-pager diff --color=always;
}
- exit $EXITVALUE