diff --git a/app/build.gradle b/app/build.gradle index 10e94a5..20f27b5 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -1,12 +1,13 @@ plugins { id "com.android.application" - id "kotlin-android" } apply plugin: "shot" android { - compileSdkVersion 30 - buildToolsVersion "30.0.2" + compileSdkVersion 34 + buildToolsVersion "34.0.0" + + namespace "com.karumi.shotconsumercompose" defaultConfig { applicationId "com.karumi.shotconsumercompose" @@ -42,16 +43,10 @@ android { sourceCompatibility JavaVersion.VERSION_1_8 targetCompatibility JavaVersion.VERSION_1_8 } - kotlinOptions { - jvmTarget = "1.8" - useIR = true - } buildFeatures { compose true } composeOptions { - kotlinCompilerExtensionVersion compose_version - kotlinCompilerVersion kotlin_version } packagingOptions { exclude "META-INF/*" @@ -70,14 +65,13 @@ shot { dependencies { - implementation "androidx.core:core-ktx:1.3.2" - implementation "androidx.appcompat:appcompat:1.2.0" - implementation "com.google.android.material:material:1.3.0" + implementation "androidx.appcompat:appcompat:1.6.1" + implementation "com.google.android.material:material:1.10.0" implementation "androidx.compose.ui:ui:$compose_version" implementation "androidx.compose.material:material:$compose_version" implementation "androidx.compose.ui:ui-tooling:$compose_version" - implementation "androidx.activity:activity-compose:1.3.0-alpha05" - implementation "androidx.lifecycle:lifecycle-runtime-ktx:2.3.1" + implementation "androidx.activity:activity-compose:1.8.0" + implementation "androidx.lifecycle:lifecycle-runtime:2.6.2" testImplementation "junit:junit:4.13.1" @@ -85,9 +79,7 @@ dependencies { androidTestImplementation "androidx.compose.ui:ui-test-junit4:$compose_version" androidTestImplementation "androidx.test.espresso:espresso-core:3.3.0" - androidTestImplementation "androidx.test:core-ktx:1.3.0" androidTestImplementation "androidx.test:core:1.3.0" androidTestImplementation "androidx.test:runner:1.3.0" androidTestImplementation "androidx.test.ext:junit:1.1.2" - androidTestImplementation "androidx.test.ext:junit-ktx:1.1.2" } diff --git a/app/src/main/java/com/karumi/shotconsumercompose/MainActivity.kt b/app/src/main/java/com/karumi/shotconsumercompose/MainActivity.kt index 20bc3e8..2c9cb86 100644 --- a/app/src/main/java/com/karumi/shotconsumercompose/MainActivity.kt +++ b/app/src/main/java/com/karumi/shotconsumercompose/MainActivity.kt @@ -31,7 +31,7 @@ class MainActivity : AppCompatActivity() { @Composable fun Greeting(name: String) { - Text(text = "Hello $name!") + Text(text = "Hello, $name!") } @Preview(showBackground = true) @@ -46,4 +46,4 @@ fun DefaultPreview() { @Composable fun RoundedCornersBox() { Box(Modifier.background(color = Color(0xFF4E62FD), shape = RoundedCornerShape(size = 20.dp)).width(100.dp).height(100.dp)) -} \ No newline at end of file +} diff --git a/app/src/main/java/com/karumi/shotconsumercompose/ui/Color.kt b/app/src/main/java/com/karumi/shotconsumercompose/ui/Color.kt index 940ab8d..481b1ce 100644 --- a/app/src/main/java/com/karumi/shotconsumercompose/ui/Color.kt +++ b/app/src/main/java/com/karumi/shotconsumercompose/ui/Color.kt @@ -2,7 +2,7 @@ package com.karumi.shotconsumercompose.ui import androidx.compose.ui.graphics.Color -val purple200 = Color(0xFFBB86FC) +val purple200 = Color(0xFF000000) val purple500 = Color(0xFF6200EE) val purple700 = Color(0xFF3700B3) -val teal200 = Color(0xFF03DAC5) \ No newline at end of file +val teal200 = Color(0xFF03DAC5) diff --git a/build.gradle b/build.gradle index 7c767ca..4dc4876 100644 --- a/build.gradle +++ b/build.gradle @@ -1,21 +1,24 @@ // Top-level build file where you can add configuration options common to all sub-projects/modules. buildscript { ext { - compose_version = '1.0.0-beta03' + compose_version = '1.5.4' } - ext.kotlin_version = "1.4.31" repositories { google() mavenLocal() mavenCentral() } dependencies { - classpath 'com.android.tools.build:gradle:7.0.0-alpha12' - classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" classpath "com.karumi:shot:5.14.1" } } +plugins { + id("com.android.application") version "8.1.0" apply false + id("com.android.library") version "8.1.0" apply false + id("org.jetbrains.kotlin.android") version "1.5.31" apply false +} + allprojects { repositories { google() diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index 442d913..e411586 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-6.8.3-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-8.4-bin.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists diff --git a/settings.gradle b/settings.gradle index 37c033e..1e97ddf 100644 --- a/settings.gradle +++ b/settings.gradle @@ -1,2 +1,13 @@ +pluginManagement { + repositories { + google() + mavenLocal() + gradlePluginPortal() + maven { + url "/home/arnold/myLocal" + } + } +} + rootProject.name = "shot-consumer-compose" include ':app'