Skip to content

Commit 39766e0

Browse files
Copilotjohnborges
andcommitted
Update to Capacitor 8.0 following official migration guides
Co-authored-by: johnborges <[email protected]>
1 parent 3a96f3f commit 39766e0

File tree

10 files changed

+46
-46
lines changed

10 files changed

+46
-46
lines changed

android/build.gradle

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
ext {
22
junitVersion = project.hasProperty('junitVersion') ? rootProject.ext.junitVersion : '4.13.2'
3-
androidxAppCompatVersion = project.hasProperty('androidxAppCompatVersion') ? rootProject.ext.androidxAppCompatVersion : '1.7.0'
4-
androidxJunitVersion = project.hasProperty('androidxJunitVersion') ? rootProject.ext.androidxJunitVersion : '1.2.1'
5-
androidxEspressoCoreVersion = project.hasProperty('androidxEspressoCoreVersion') ? rootProject.ext.androidxEspressoCoreVersion : '3.6.1'
3+
androidxAppCompatVersion = project.hasProperty('androidxAppCompatVersion') ? rootProject.ext.androidxAppCompatVersion : '1.7.1'
4+
androidxJunitVersion = project.hasProperty('androidxJunitVersion') ? rootProject.ext.androidxJunitVersion : '1.3.0'
5+
androidxEspressoCoreVersion = project.hasProperty('androidxEspressoCoreVersion') ? rootProject.ext.androidxEspressoCoreVersion : '3.7.0'
66
}
77

88
buildscript {
@@ -11,34 +11,34 @@ buildscript {
1111
mavenCentral()
1212
}
1313
dependencies {
14-
classpath 'com.android.tools.build:gradle:8.7.2'
14+
classpath 'com.android.tools.build:gradle:8.13.0'
1515
}
1616
}
1717

1818
apply plugin: 'com.android.library'
1919

2020
android {
21-
namespace "com.getcapacitor.community.appicon"
22-
compileSdkVersion project.hasProperty('compileSdkVersion') ? rootProject.ext.compileSdkVersion : 35
21+
namespace = "com.getcapacitor.community.appicon"
22+
compileSdk = project.hasProperty('compileSdkVersion') ? rootProject.ext.compileSdkVersion : 36
2323
defaultConfig {
24-
minSdkVersion project.hasProperty('minSdkVersion') ? rootProject.ext.minSdkVersion : 24
25-
targetSdkVersion project.hasProperty('targetSdkVersion') ? rootProject.ext.targetSdkVersion : 35
26-
versionCode 1
27-
versionName "1.0"
28-
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
24+
minSdkVersion = project.hasProperty('minSdkVersion') ? rootProject.ext.minSdkVersion : 24
25+
targetSdkVersion = project.hasProperty('targetSdkVersion') ? rootProject.ext.targetSdkVersion : 36
26+
versionCode = 1
27+
versionName = "1.0"
28+
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
2929
}
3030
buildTypes {
3131
release {
32-
minifyEnabled false
32+
minifyEnabled = false
3333
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
3434
}
3535
}
36-
lintOptions {
37-
abortOnError false
36+
lint {
37+
abortOnError = false
3838
}
3939
compileOptions {
40-
sourceCompatibility JavaVersion.VERSION_21
41-
targetCompatibility JavaVersion.VERSION_21
40+
sourceCompatibility = JavaVersion.VERSION_21
41+
targetCompatibility = JavaVersion.VERSION_21
4242
}
4343
}
4444

android/gradle/wrapper/gradle-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-8.11.1-all.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.3-all.zip
44
networkTimeout=10000
55
validateDistributionUrl=true
66
zipStoreBase=GRADLE_USER_HOME

example/android/app/build.gradle

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,24 @@
11
apply plugin: 'com.android.application'
22

33
android {
4-
namespace "com.example.app"
5-
compileSdk rootProject.ext.compileSdkVersion
4+
namespace = "com.example.app"
5+
compileSdk = rootProject.ext.compileSdkVersion
66
defaultConfig {
7-
applicationId "com.example.app"
8-
minSdkVersion rootProject.ext.minSdkVersion
9-
targetSdkVersion rootProject.ext.targetSdkVersion
10-
versionCode 1
11-
versionName "1.0"
12-
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
7+
applicationId = "com.example.app"
8+
minSdkVersion = rootProject.ext.minSdkVersion
9+
targetSdkVersion = rootProject.ext.targetSdkVersion
10+
versionCode = 1
11+
versionName = "1.0"
12+
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
1313
aaptOptions {
1414
// Files and dirs to omit from the packaged assets dir, modified to accommodate modern web apps.
1515
// Default: https://android.googlesource.com/platform/frameworks/base/+/282e181b58cf72b6ca770dc7ca5f91f135444502/tools/aapt/AaptAssets.cpp#61
16-
ignoreAssetsPattern '!.svn:!.git:!.ds_store:!*.scc:.*:!CVS:!thumbs.db:!picasa.ini:!*~'
16+
ignoreAssetsPattern = '!.svn:!.git:!.ds_store:!*.scc:.*:!CVS:!thumbs.db:!picasa.ini:!*~'
1717
}
1818
}
1919
buildTypes {
2020
release {
21-
minifyEnabled false
21+
minifyEnabled = false
2222
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
2323
}
2424
}

example/android/app/src/main/AndroidManifest.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
android:name=".MainActivity"
1515
android:exported="true"
1616
android:launchMode="singleTask"
17-
android:configChanges="orientation|keyboardHidden|keyboard|screenSize|locale|smallestScreenSize|screenLayout|uiMode|navigation"
17+
android:configChanges="orientation|keyboardHidden|keyboard|screenSize|locale|smallestScreenSize|screenLayout|uiMode|navigation|density"
1818
android:label="@string/title_activity_main"
1919
android:theme="@style/AppTheme.NoActionBarLaunch">
2020

example/android/build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@ buildscript {
77
mavenCentral()
88
}
99
dependencies {
10-
classpath 'com.android.tools.build:gradle:8.7.2'
11-
classpath 'com.google.gms:google-services:4.4.2'
10+
classpath 'com.android.tools.build:gradle:8.13.0'
11+
classpath 'com.google.gms:google-services:4.4.4'
1212

1313
// NOTE: Do not place your application dependencies here; they belong
1414
// in the individual module build.gradle files

example/android/gradle/wrapper/gradle-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-8.11.1-all.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.3-all.zip
44
networkTimeout=10000
55
validateDistributionUrl=true
66
zipStoreBase=GRADLE_USER_HOME

example/android/variables.gradle

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
ext {
22
minSdkVersion = 24
3-
compileSdkVersion = 35
4-
targetSdkVersion = 35
5-
androidxActivityVersion = '1.9.2'
6-
androidxAppCompatVersion = '1.7.0'
7-
androidxCoordinatorLayoutVersion = '1.2.0'
8-
androidxCoreVersion = '1.15.0'
9-
androidxFragmentVersion = '1.8.4'
10-
coreSplashScreenVersion = '1.0.1'
11-
androidxWebkitVersion = '1.12.1'
3+
compileSdkVersion = 36
4+
targetSdkVersion = 36
5+
androidxActivityVersion = '1.11.0'
6+
androidxAppCompatVersion = '1.7.1'
7+
androidxCoordinatorLayoutVersion = '1.3.0'
8+
androidxCoreVersion = '1.17.0'
9+
androidxFragmentVersion = '1.8.9'
10+
coreSplashScreenVersion = '1.2.0'
11+
androidxWebkitVersion = '1.14.0'
1212
junitVersion = '4.13.2'
13-
androidxJunitVersion = '1.2.1'
14-
androidxEspressoCoreVersion = '3.6.1'
15-
cordovaAndroidVersion = '10.1.1'
13+
androidxJunitVersion = '1.3.0'
14+
androidxEspressoCoreVersion = '3.7.0'
15+
cordovaAndroidVersion = '14.0.1'
1616
}

example/package-lock.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package-lock.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@
6666
"typescript": "^5.7.3"
6767
},
6868
"peerDependencies": {
69-
"@capacitor/core": ">=7.0.0 || >=8.0.0-0"
69+
"@capacitor/core": "^8.0.0"
7070
},
7171
"prettier": "@ionic/prettier-config",
7272
"swiftlint": "@ionic/swiftlint-config",

0 commit comments

Comments
 (0)