blob: 01bd2481357b3fa29a89c736303f17df673230d6 [file] [log] [blame]
gfanc351bd02018-06-11 11:25:36 -07001#!/bin/bash
2set +e
3
4MISC_STATUS=0
5
6# check that all targetSdkVersion are 26+
7# test "$(grep -H targetSdkVersion */app/build.gradle | tee /dev/stderr | cut -d= -f 2 | xargs -n1 echo | sort | uniq | wc -l)" = "2"
8# check that there is no tabs in AndroidManifest
9(! grep -n $'\t' */*/src/main/AndroidManifest.xml) | cat -t;
10MISC_STATUS=$(($MISC_STATUS + ${PIPESTATUS[0]}))
11
12# check that there is no trailing spaces in AndroidManifest
13(! grep -E '\s+$' */*/src/main/AndroidManifest.xml) | cat -e;
14MISC_STATUS=$(($MISC_STATUS + ${PIPESTATUS[0]}))
15
16# populate the error to final status
17if [[ "$MISC_STATUS" -ne 0 ]]; then
18 SAMPLE_CI_RESULT=$(($SAMPLE_CI_RESULT + 1))
19fi