-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[DEVOPS] Define dev->feature->main PR workflows (#1)
* Define dev->feature->main PR workflows * Fix job descriptions * remove unused androidx dependencies * set build-logic rootProject.name * format plugins by groups * rename kotlin Jvm plugin * Remove android compose configuration; rely on compose multiplatform plugin * uncomment source sets; fix typo * move android project files from main to androidMain * revert to kotlin android plugin over kotlin multiplatform * Revert "move android project files from main to androidMain" This reverts commit a8fed91. * set jvm target to same bytecode level as android target * add androidx activity compose dependency * add compose preview and :core:entities dependencies * Implement jvm platform
- Loading branch information
Showing
10 changed files
with
139 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
name: "PR Checks for `main` documentation" | ||
on: | ||
pull_request: | ||
types: | ||
- opened # initially opened | ||
- reopened # closed then opened again | ||
- synchronize # any changes pushed | ||
branches: | ||
- main | ||
paths: # Only run checks on changes to documentation | ||
- "**/docs/*" | ||
- "*/README.md" | ||
|
||
jobs: | ||
build: | ||
name: "Generate Latest Documentation" | ||
runs-on: [ubuntu-22.04] | ||
if: github.event.pull_request.draft == false # ignore draft pull requests | ||
# env: | ||
# | ||
# outputs: | ||
# | ||
steps: | ||
- name: "Checkout Project" | ||
uses: actions/checkout@v4 | ||
- name: "Setup Java 17" | ||
uses: actions/setup-java@v4 | ||
with: | ||
distribution: 'temurin' # See 'Supported distributions' for available options | ||
java-version: '17' | ||
- name: "Setup Gradle" | ||
uses: gradle/actions/setup-gradle@v3 | ||
|
||
- name: "Generate Documentation" | ||
run: ./gradlew dokka | ||
|
||
# - run: upload documentation to GitHub pages site |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
name: "PR Checks for feature branches" | ||
on: | ||
pull_request: | ||
types: | ||
- opened # initially opened | ||
- reopened # closed then opened again | ||
- synchronize # any changes pushed | ||
branches: | ||
- "feature/*" | ||
paths-ignore: # Only run checks on changes to code | ||
- "**/docs/*" | ||
- "*/README.md" | ||
|
||
jobs: | ||
build: | ||
name: "Setup and Build Project (Feature)" | ||
runs-on: [ubuntu-22.04] | ||
if: github.event.pull_request.draft == false # ignore draft pull requests | ||
# env: | ||
# | ||
# outputs: | ||
# | ||
steps: | ||
- name: "Checkout Project" | ||
uses: actions/checkout@v4 | ||
- name: "Setup Java 17" | ||
uses: actions/setup-java@v4 | ||
with: | ||
distribution: 'temurin' # See 'Supported distributions' for available options | ||
java-version: '17' | ||
- name: "Setup Gradle" | ||
uses: gradle/actions/setup-gradle@v3 | ||
|
||
- name: "Build: Assemble and Test entire project" | ||
run: ./gradlew build | ||
|
||
# - run: ./gradlew generate coverage report, upload test/coverage reports |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
name: "PR Checks for `main`" | ||
on: | ||
pull_request: | ||
types: | ||
- opened # initially opened | ||
- reopened # closed then opened again | ||
- synchronize # any changes pushed | ||
branches: | ||
- main | ||
paths-ignore: # Only run checks on changes to code | ||
- "**/docs/*" | ||
- "*/README.md" | ||
|
||
jobs: | ||
build: | ||
name: "Setup and Build Project" | ||
runs-on: [ubuntu-22.04] | ||
if: github.event.pull_request.draft == false # ignore draft pull requests | ||
# env: | ||
# | ||
# outputs: | ||
# | ||
steps: | ||
- name: "Checkout Project" | ||
uses: actions/checkout@v4 | ||
- name: "Setup Java 17" | ||
uses: actions/setup-java@v4 | ||
with: | ||
distribution: 'temurin' # See 'Supported distributions' for available options | ||
java-version: '17' | ||
- name: "Setup Gradle" | ||
uses: gradle/actions/setup-gradle@v3 | ||
|
||
- name: "Build: Assemble and Test entire project" | ||
run: ./gradlew build | ||
|
||
# - run: ./gradlew generate coverage report, upload test/coverage reports |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,4 +11,5 @@ dependencyResolutionManagement { | |
// } | ||
} | ||
|
||
rootProject.name = "build-logic" | ||
include(":conventions") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
8 changes: 8 additions & 0 deletions
8
core/entities/src/jvmMain/kotlin/org/pointyware/painteddogs/core/entities/Platform.jvm.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
package org.pointyware.painteddogs.core.entities | ||
|
||
class JvmPlatform : Platform { | ||
override val name: String = "JVM ${System.getProperty("os.name")}" | ||
} | ||
actual fun getPlatform(): Platform { | ||
return JvmPlatform() | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,17 @@ | ||
[versions] | ||
agp = "8.2.2" | ||
androidx-compose = "1.8.2" | ||
kotlin = "1.9.21" | ||
compose = "1.5.12" | ||
androidx-activityCompose = "1.8.2" | ||
|
||
[libraries] | ||
kotlin-test = { module = "org.jetbrains.kotlin:kotlin-test", version.ref = "kotlin" } | ||
androidx-activity-compose = { module = "androidx.activity:activity-compose", version.ref = "androidx-activityCompose" } | ||
androidx-activityCompose = { module = "androidx.activity:activity-compose", version.ref = "androidx-compose" } | ||
|
||
[plugins] | ||
androidApplication = { id = "com.android.application", version.ref = "agp" } | ||
androidLibrary = { id = "com.android.library", version.ref = "agp" } | ||
androidApplication = { id = "com.android.application", version.ref = "agp" } | ||
androidLibrary = { id = "com.android.library", version.ref = "agp" } | ||
composeMultiplatform = { id = "org.jetbrains.compose", version.ref = "compose" } | ||
kotlinAndroid = { id = "org.jetbrains.kotlin.android", version.ref = "kotlin" } | ||
kotlinAndroid = { id = "org.jetbrains.kotlin.android", version.ref = "kotlin" } | ||
kotlinJvm = { id = "org.jetbrains.kotlin.jvm", version.ref = "kotlin" } | ||
kotlinMultiplatform = { id = "org.jetbrains.kotlin.multiplatform", version.ref = "kotlin" } | ||
org-jetbrains-kotlin-jvm = { id = "org.jetbrains.kotlin.jvm", version.ref = "kotlin" } |