Skip to content

Commit

Permalink
updated the workflow and dokka task
Browse files Browse the repository at this point in the history
  • Loading branch information
lalwani committed Feb 20, 2024
1 parent 47592d6 commit 3aab010
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 8 deletions.
12 changes: 5 additions & 7 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
uses: actions/setup-java@v2
with:
distribution: 'adopt'
java-version: '8'
java-version: '17'
- name: Lint and Unit tests
run: ./gradlew check --stacktrace
- name: Upload lint and test reports
Expand All @@ -25,7 +25,6 @@ jobs:
path: |
./core-android/build/reports
./rides-android/build/reports
test:
runs-on: macOS-latest # enables hardware acceleration in the virtual machine, required for emulator testing
strategy:
Expand All @@ -40,7 +39,7 @@ jobs:
uses: actions/setup-java@v2
with:
distribution: 'adopt'
java-version: '8'
java-version: '17'
- name: Emulator tests
uses: reactivecircus/android-emulator-runner@v2
with:
Expand All @@ -57,7 +56,6 @@ jobs:
path: |
./core-android/build/reports
./rides-android/build/reports
upload-snapshots:
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/main' && github.event_name != 'pull_request'
Expand All @@ -73,9 +71,9 @@ jobs:
uses: actions/setup-java@v2
with:
distribution: 'adopt'
java-version: '8'
java-version: '17'
- name: Upload snapshots
run: ./gradlew uploadArchives --stacktrace
run: ./gradlew publish --stacktrace
env:
ORG_GRADLE_PROJECT_SONATYPE_NEXUS_USERNAME: ${{ secrets.SonatypeUsername }}
ORG_GRADLE_PROJECT_SONATYPE_NEXUS_PASSWORD: ${{ secrets.SonatypePassword }}
ORG_GRADLE_PROJECT_SONATYPE_NEXUS_PASSWORD: ${{ secrets.SonatypePassword }}
14 changes: 13 additions & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,10 @@ val targetSdkVersion: Int = libs.versions.targetSdkVersion.get().toInt()
val minSdkVersion: Int = libs.versions.minSdkVersion.get().toInt()
val jvmTargetVersion = libs.versions.jvmTarget

tasks.dokkaHtmlMultiModule {
outputDirectory.set(rootDir.resolve("docs/api/2.x"))
includes.from(project.layout.projectDirectory.file("README.md"))
}

subprojects {

Expand Down Expand Up @@ -93,12 +97,20 @@ subprojects {
moduleVersion.set(project.property("VERSION_NAME").toString())
dokkaSourceSets.configureEach {
skipDeprecated.set(true)
includes.from("README.md")
suppressGeneratedFiles.set(true)
suppressInheritedMembers.set(true)
externalDocumentationLink {
url.set(URI("https://kotlin.github.io/kotlinx.coroutines/index.html").toURL())
}
perPackageOption {
// language=RegExp
matchingRegex.set(".*\\.internal\\..*")
suppress.set(true)
}
val moduleMd = project.layout.projectDirectory.file("README.md")
if (moduleMd.asFile.exists()) {
includes.from(moduleMd)
}
}
}

Expand Down

0 comments on commit 3aab010

Please sign in to comment.