Skip to content

Commit

Permalink
Merge pull request #4 from frogobox/develop/update-sdk-version
Browse files Browse the repository at this point in the history
DEVELOP :: Update SDK Version
  • Loading branch information
amirisback committed Jun 14, 2023
2 parents 1f4f754 + ed8f0d2 commit 17712e9
Show file tree
Hide file tree
Showing 8 changed files with 51 additions and 54 deletions.
61 changes: 27 additions & 34 deletions .github/workflows/android-ci.yml
Original file line number Diff line number Diff line change
@@ -1,55 +1,48 @@
name: Android CI

env:
# The name of the main module repository
main_project_module: app

# The name of the Play Store
playstore_name: Frogobox ID

on:
# workflow_dispatch - for clicking
# Triggers the workflow on push or pull request events but only for default and protected branches
push:
branches: [ master ]
pull_request:
branches: [ master ]

workflow_dispatch:
# The workflow will be dispatched to the default queue

jobs:
build:

runs-on: ubuntu-latest
permissions:
contents: read
packages: write

steps:
- uses: actions/checkout@v1
- uses: actions/checkout@v3

- name: Set Up JDK 11
uses: actions/setup-java@v1
# Set Current Date As Env Variable
- name: Set current date as env variable
run: echo "date_today=$(date +'%Y-%m-%d')" >> $GITHUB_ENV

# Set Repository Name As Env Variable
- name: Set repository name as env variable
run: echo "repository_name=$(echo '${{ github.repository }}' | awk -F '/' '{print $2}')" >> $GITHUB_ENV

- name: Set Up JDK
uses: actions/setup-java@v3
with:
java-version: 11
distribution: 'zulu' # See 'Supported distributions' for available options
java-version: '17'
cache: 'gradle'

- name: Change wrapper permissions
run: chmod +x ./gradlew

- name: Run tests
run: ./gradlew test

# Run Build Project
- name: Build project
run: ./gradlew build

# Create APK Debug
- name: Build apk debug project (APK)
run: ./gradlew assembleDebug

# Create APK Release
- name: Build apk release project (APK)
run: ./gradlew assemble

# Create Bundle AAB Release
# Noted for main module build [module-name]:bundleRelease
- name: Build app bundle release (AAB)
run: ./gradlew app:bundleRelease

# Upload Artifact Build
# Noted For Output [module-name]/build/outputs/
- name: Upload build APK / AAB
uses: actions/upload-artifact@v2
with:
name: App bundle(s) and APK(s) generated
path: app/build/outputs/
- name: Build gradle project
run: ./gradlew build
12 changes: 6 additions & 6 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
plugins {
id("com.android.application")
id("org.jetbrains.kotlin.android")
id("kotlin-kapt")
id("com.google.devtools.ksp")
}

android {
Expand Down Expand Up @@ -71,13 +71,13 @@ android {
}

compileOptions {
sourceCompatibility = JavaVersion.VERSION_11
targetCompatibility = JavaVersion.VERSION_11
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
}

tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile> {
kotlinOptions {
jvmTarget = JavaVersion.VERSION_11.toString()
kotlin {
jvmToolchain {
languageVersion.set(JavaLanguageVersion.of("17"))
}
}

Expand Down
5 changes: 3 additions & 2 deletions build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
// Top-level build file where you can add configuration options common to all sub-projects/modules.
plugins {
id("com.android.application") version "7.4.2" apply false
id("com.android.library") version "7.4.2" apply false
id("com.android.application") version "8.0.2" apply false
id("com.android.library") version "8.0.2" apply false
id("com.google.devtools.ksp") version "1.8.21-1.0.11" apply false
id("org.jetbrains.kotlin.android") version DependencyGradle.KOTLIN_VERSION apply false
}

Expand Down
2 changes: 1 addition & 1 deletion buildSrc/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,5 @@ repositories {

dependencies{
// library open-build-src
implementation("com.github.frogobox:open-build-src:2.1.1")
implementation("com.github.frogobox:open-build-src:2.1.8")
}
12 changes: 6 additions & 6 deletions frogolib/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
plugins {
id("com.android.library")
id("org.jetbrains.kotlin.android")
id("kotlin-kapt")
id("com.google.devtools.ksp")
`maven-publish`
}

Expand Down Expand Up @@ -38,13 +38,13 @@ android {
}

compileOptions {
sourceCompatibility = JavaVersion.VERSION_11
targetCompatibility = JavaVersion.VERSION_11
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
}

tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile> {
kotlinOptions {
jvmTarget = JavaVersion.VERSION_11.toString()
kotlin {
jvmToolchain {
languageVersion.set(JavaLanguageVersion.of("17"))
}
}

Expand Down
6 changes: 3 additions & 3 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ kotlin.code.style=official
# resources declared in the library itself and none from the library's dependencies,
# thereby reducing the size of the R class for that library
android.nonTransitiveRClass=true
# Software Components will not be created automatically for Maven publishing from Android Gradle Plugin 8.0. To opt-in to the future behavior
android.disableAutomaticComponentCreation=true

gpr.user=amirisback
gpr.key=
gpr.key=
android.defaults.buildfeatures.buildconfig=true
android.nonFinalResIds=false
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-7.5-all.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.0-all.zip
5 changes: 4 additions & 1 deletion jitpack.yml
Original file line number Diff line number Diff line change
@@ -1,2 +1,5 @@
jdk:
- openjdk11
- openjdk17
before_install:
- sdk install java 17.0.1-open
- sdk use java 17.0.1-open

0 comments on commit 17712e9

Please sign in to comment.