From 5bd14afb583128fa56ab425efb188231202659ba Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lucas=20Concei=C3=A7=C3=A3o?= Date: Thu, 2 Jul 2020 14:19:45 -0300 Subject: [PATCH 1/3] Add Dokka plugin --- build.gradle | 2 ++ testcommons/build.gradle | 1 + 2 files changed, 3 insertions(+) diff --git a/build.gradle b/build.gradle index b6f90fd..5861927 100644 --- a/build.gradle +++ b/build.gradle @@ -3,6 +3,7 @@ buildscript { ext.kotlin_version = '1.3.72' ext.android_tools_gradle = '3.5.1' + ext.dokka_version = '0.10.1' repositories { google() @@ -14,6 +15,7 @@ buildscript { classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" classpath 'com.github.dcendents:android-maven-gradle-plugin:2.1' + classpath "org.jetbrains.dokka:dokka-gradle-plugin:$dokka_version" } } diff --git a/testcommons/build.gradle b/testcommons/build.gradle index 27359d0..f26a1d8 100644 --- a/testcommons/build.gradle +++ b/testcommons/build.gradle @@ -1,5 +1,6 @@ apply plugin: 'com.android.library' apply plugin: 'kotlin-android' +apply plugin: 'org.jetbrains.dokka' apply from: "$rootDir/tools/publish.gradle" apply from: "$rootDir/tools/ktlint.gradle" From 16c1d6d01436e720fbfb40689db51aed80280a03 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lucas=20Concei=C3=A7=C3=A3o?= Date: Thu, 2 Jul 2020 14:20:31 -0300 Subject: [PATCH 2/3] Add information about generating the documentation --- Makefile | 3 +++ README.md | 6 +++++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 7f280d5..fd7806d 100644 --- a/Makefile +++ b/Makefile @@ -7,5 +7,8 @@ lint: run-lint-rules: ./gradlew ktlintFormat +documentation: + ./gradlew dokka + publish-test-lib-prod: clean ./gradlew build publish --stacktrace diff --git a/README.md b/README.md index b7dd0eb..4afa63d 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,11 @@ Copy and paste the file **github_credentials.properties.sample** and rename it t **Important:** The file **github_credentials.properties** can not be committed. ### Documentation -Example usages can be found as comments on top of every class and function. +Example usages can be found as comments on top of every class and function. For a complete report with all functions run the following command: + + make documentation + +The report will be available at `testcommons/build/dokka/testcommons/index.html` ## How to contribute You can contribute submitting [pull requests](https://github.com/natura-cosmeticos/Nat-Test-Commons/pulls). From 100bad96a086ab3d65d9d40af465dfa7d91758d0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lucas=20Concei=C3=A7=C3=A3o?= Date: Thu, 2 Jul 2020 14:21:14 -0300 Subject: [PATCH 3/3] Fix classpath declarations --- build.gradle | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/build.gradle b/build.gradle index 5861927..b702097 100644 --- a/build.gradle +++ b/build.gradle @@ -2,7 +2,8 @@ buildscript { ext.kotlin_version = '1.3.72' - ext.android_tools_gradle = '3.5.1' + ext.android_tools_gradle_version = '3.5.1' + ext.maven_gradle_version = '2.1' ext.dokka_version = '0.10.1' repositories { @@ -11,10 +12,9 @@ buildscript { } dependencies { - classpath "com.android.tools.build:gradle:$android_tools_gradle" + classpath "com.android.tools.build:gradle:$android_tools_gradle_version" classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" - classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" - classpath 'com.github.dcendents:android-maven-gradle-plugin:2.1' + classpath "com.github.dcendents:android-maven-gradle-plugin:$maven_gradle_version" classpath "org.jetbrains.dokka:dokka-gradle-plugin:$dokka_version" } }