diff --git a/.github/workflows/pull-request.yml b/.github/workflows/pull-request.yml
index dac5e6fb..dd09d092 100644
--- a/.github/workflows/pull-request.yml
+++ b/.github/workflows/pull-request.yml
@@ -1,7 +1,8 @@
name: "Pull request"
on:
pull_request:
- types: [opened, synchronize, reopened]
+ types: [ opened, synchronize, reopened ]
+
jobs:
validation:
name: Gradle Wrapper Validation
@@ -9,6 +10,34 @@ jobs:
steps:
- uses: actions/checkout@v2
- uses: gradle/wrapper-validation-action@v1
+
+ verify-google-java-format:
+ name: Google Java Format Verification
+ runs-on: ubuntu-latest
+ needs: validation
+ steps:
+ - name: Checkout
+ uses: actions/checkout@v2
+ - name: Setup Java
+ uses: actions/setup-java@v2
+ with:
+ distribution: 'zulu'
+ java-version: 15
+ - name: Cache Gradle
+ uses: actions/cache@v2
+ env:
+ java-version: 15
+ with:
+ path: |
+ ~/.gradle/caches
+ ~/.gradle/wrapper
+ key: ${{ runner.os }}-${{ env.java-version }}-gradle-${{ hashFiles('**/*.gradle*') }}
+ restore-keys: ${{ runner.os }}-${{ env.java-version }}-gradle-
+ - name: Make gradlew executable
+ run: chmod +x ./gradlew
+ - name: Gradle Check
+ run: ./gradlew --info build -x test
+
test:
name: Test run
strategy:
@@ -35,18 +64,18 @@ jobs:
~/.gradle/caches
~/.gradle/wrapper
key: ${{ runner.os }}-${{ env.java-version }}-gradle-${{ hashFiles('**/*.gradle*') }}
- restore-keys: |
- ${{ runner.os }}-${{ env.java-version }}-gradle-
+ restore-keys: ${{ runner.os }}-${{ env.java-version }}-gradle-
- name: Make gradlew executable (non-Windows only)
if: matrix.os != 'windows-latest'
run: chmod +x ./gradlew
- name: Gradle Check (non-Windows)
if: matrix.os != 'windows-latest'
- run: ./gradlew --info check
+ run: ./gradlew --info check -x verifyGoogleJavaFormat
- name: Gradle Check (Windows)
if: matrix.os == 'windows-latest'
shell: cmd
- run: gradlew --info check
+ run: gradlew --info check -x verifyGoogleJavaFormat
+
build:
name: Sonar analysis
needs: validation
@@ -83,4 +112,4 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
- run: ./gradlew build jacocoTestReport sonarqube --info
+ run: ./gradlew build jacocoTestReport sonarqube --info -x verifyGoogleJavaFormat
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml
index eea5e7f6..407451bf 100644
--- a/.github/workflows/release.yml
+++ b/.github/workflows/release.yml
@@ -8,6 +8,7 @@ jobs:
steps:
- uses: actions/checkout@v2
- uses: gradle/wrapper-validation-action@v1
+
test:
name: Test run
needs: validation
@@ -34,7 +35,8 @@ jobs:
- name: Make gradlew executable
run: chmod +x ./gradlew
- name: Gradle Check
- run: ./gradlew --info check
+ run: ./gradlew --info check -x verifyGoogleJavaFormat
+
build:
name: Publish release
needs: test
diff --git a/.github/workflows/snapshot.yml b/.github/workflows/snapshot.yml
index 296977f2..49b85102 100644
--- a/.github/workflows/snapshot.yml
+++ b/.github/workflows/snapshot.yml
@@ -11,6 +11,34 @@ jobs:
steps:
- uses: actions/checkout@v2
- uses: gradle/wrapper-validation-action@v1
+
+ verify-google-java-format:
+ name: Google Java Format Verification
+ runs-on: ubuntu-latest
+ needs: validation
+ steps:
+ - name: Checkout
+ uses: actions/checkout@v2
+ - name: Setup Java
+ uses: actions/setup-java@v2
+ with:
+ distribution: 'zulu'
+ java-version: 15
+ - name: Cache Gradle
+ uses: actions/cache@v2
+ env:
+ java-version: 15
+ with:
+ path: |
+ ~/.gradle/caches
+ ~/.gradle/wrapper
+ key: ${{ runner.os }}-${{ env.java-version }}-gradle-${{ hashFiles('**/*.gradle*') }}
+ restore-keys: ${{ runner.os }}-${{ env.java-version }}-gradle-
+ - name: Make gradlew executable
+ run: chmod +x ./gradlew
+ - name: Gradle Check
+ run: ./gradlew --info build -x test
+
test:
name: Test run
needs: validation
@@ -37,7 +65,8 @@ jobs:
- name: Make gradlew executable
run: chmod +x ./gradlew
- name: Gradle Check
- run: ./gradlew --info check
+ run: ./gradlew --info check -x verifyGoogleJavaFormat
+
build:
name: Publish snapshot
needs: test
@@ -68,7 +97,8 @@ jobs:
env:
OSS_USER_TOKEN_KEY: ${{ secrets.OSS_USER_TOKEN_KEY }}
OSS_USER_TOKEN_PASS: ${{ secrets.OSS_USER_TOKEN_PASS }}
- run: ./gradlew clean build publish -x test
+ run: ./gradlew clean build publish -x test verifyGoogleJavaFormat
+
sonar:
name: Sonar analysis
needs: validation
@@ -98,4 +128,5 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
- run: ./gradlew build jacocoTestReport sonarqube --info
+ if: env.SONAR_TOKEN != null
+ run: ./gradlew build jacocoTestReport sonarqube --info -x verifyGoogleJavaFormat
diff --git a/.gitignore b/.gitignore
index 20acee31..5713e1ce 100644
--- a/.gitignore
+++ b/.gitignore
@@ -3,7 +3,8 @@ build/
*.iml
*.ipr
*.iws
-**/.idea/
+.idea/*
+!.idea/codeStyles/
target/
/out/
.classpath
diff --git a/.idea/codeStyles/Project.xml b/.idea/codeStyles/Project.xml
new file mode 100644
index 00000000..4809a830
--- /dev/null
+++ b/.idea/codeStyles/Project.xml
@@ -0,0 +1,583 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ xmlns:android
+
+ ^$
+
+
+
+
+
+
+
+
+ xmlns:.*
+
+ ^$
+
+
+ BY_NAME
+
+
+
+
+
+
+ .*:id
+
+ http://schemas.android.com/apk/res/android
+
+
+
+
+
+
+
+
+ style
+
+ ^$
+
+
+
+
+
+
+
+
+ .*
+
+ ^$
+
+
+ BY_NAME
+
+
+
+
+
+
+ .*:.*Style
+
+ http://schemas.android.com/apk/res/android
+
+
+ BY_NAME
+
+
+
+
+
+
+ .*:layout_width
+
+ http://schemas.android.com/apk/res/android
+
+
+
+
+
+
+
+
+ .*:layout_height
+
+ http://schemas.android.com/apk/res/android
+
+
+
+
+
+
+
+
+ .*:layout_weight
+
+ http://schemas.android.com/apk/res/android
+
+
+
+
+
+
+
+
+ .*:layout_margin
+
+ http://schemas.android.com/apk/res/android
+
+
+
+
+
+
+
+
+ .*:layout_marginTop
+
+ http://schemas.android.com/apk/res/android
+
+
+
+
+
+
+
+
+ .*:layout_marginBottom
+
+ http://schemas.android.com/apk/res/android
+
+
+
+
+
+
+
+
+ .*:layout_marginStart
+
+ http://schemas.android.com/apk/res/android
+
+
+
+
+
+
+
+
+ .*:layout_marginEnd
+
+ http://schemas.android.com/apk/res/android
+
+
+
+
+
+
+
+
+ .*:layout_marginLeft
+
+ http://schemas.android.com/apk/res/android
+
+
+
+
+
+
+
+
+ .*:layout_marginRight
+
+ http://schemas.android.com/apk/res/android
+
+
+
+
+
+
+
+
+ .*:layout_.*
+
+ http://schemas.android.com/apk/res/android
+
+
+ BY_NAME
+
+
+
+
+
+
+ .*:padding
+
+ http://schemas.android.com/apk/res/android
+
+
+
+
+
+
+
+
+ .*:paddingTop
+
+ http://schemas.android.com/apk/res/android
+
+
+
+
+
+
+
+
+ .*:paddingBottom
+
+ http://schemas.android.com/apk/res/android
+
+
+
+
+
+
+
+
+ .*:paddingStart
+
+ http://schemas.android.com/apk/res/android
+
+
+
+
+
+
+
+
+ .*:paddingEnd
+
+ http://schemas.android.com/apk/res/android
+
+
+
+
+
+
+
+
+ .*:paddingLeft
+
+ http://schemas.android.com/apk/res/android
+
+
+
+
+
+
+
+
+ .*:paddingRight
+
+ http://schemas.android.com/apk/res/android
+
+
+
+
+
+
+
+
+ .*
+ http://schemas.android.com/apk/res/android
+
+
+ BY_NAME
+
+
+
+
+
+
+ .*
+ http://schemas.android.com/apk/res-auto
+
+
+ BY_NAME
+
+
+
+
+
+
+ .*
+ http://schemas.android.com/tools
+
+
+ BY_NAME
+
+
+
+
+
+
+ .*
+ .*
+
+
+ BY_NAME
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/codeStyles/codeStyleConfig.xml b/.idea/codeStyles/codeStyleConfig.xml
new file mode 100644
index 00000000..79ee123c
--- /dev/null
+++ b/.idea/codeStyles/codeStyleConfig.xml
@@ -0,0 +1,5 @@
+
+
+
+
+
\ No newline at end of file