Skip to content

Commit

Permalink
Merge pull request #63 from BranchMetrics/gdeluna-branch/SDK-1605
Browse files Browse the repository at this point in the history
Capacitor 4 support
  • Loading branch information
gdeluna-branch authored Sep 2, 2022
2 parents b7f6602 + 0dc439d commit d48d070
Show file tree
Hide file tree
Showing 7 changed files with 30 additions and 23 deletions.
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
Branch Capacitor SDK change log

- 5.0.0

- Updates the core capacitor plugin to 4.0.1
- Android minSdk bumped to 22
- iOS platform bumped to 13
- Android Branch SDK updated to 5.2.3 which targets 32 as well.
- Android Branch SDK dependency type changed from `implementation` to `api` to keep references consistent and integration simpler

- 4.2.0

- Update Android SDK to 5.2.0 https://github.com/BranchMetrics/android-branch-deep-linking-attribution/releases/tag/5.2.0
Expand Down
23 changes: 11 additions & 12 deletions android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -7,28 +7,28 @@ def getNpmVersion() {
}

ext {
junitVersion = project.hasProperty('junitVersion') ? rootProject.ext.junitVersion : '4.12'
androidxJunitVersion = project.hasProperty('androidxJunitVersion') ? rootProject.ext.androidxJunitVersion : '1.1.1'
androidxEspressoCoreVersion = project.hasProperty('androidxEspressoCoreVersion') ? rootProject.ext.androidxEspressoCoreVersion : '3.2.0'
junitVersion = project.hasProperty('junitVersion') ? rootProject.ext.junitVersion : '4.13.2'
androidxJunitVersion = project.hasProperty('androidxJunitVersion') ? rootProject.ext.androidxJunitVersion : '1.1.3'
androidxEspressoCoreVersion = project.hasProperty('androidxEspressoCoreVersion') ? rootProject.ext.androidxEspressoCoreVersion : '3.4.0'
}

buildscript {
repositories {
google()
jcenter()
mavenCentral()
}
dependencies {
classpath 'com.android.tools.build:gradle:3.6.1'
classpath 'com.android.tools.build:gradle:7.2.2'
}
}

apply plugin: 'com.android.library'

android {
compileSdkVersion project.hasProperty('compileSdkVersion') ? rootProject.ext.compileSdkVersion : 29
compileSdkVersion project.hasProperty('compileSdkVersion') ? rootProject.ext.compileSdkVersion : 32
defaultConfig {
minSdkVersion project.hasProperty('minSdkVersion') ? rootProject.ext.minSdkVersion : 21
targetSdkVersion project.hasProperty('targetSdkVersion') ? rootProject.ext.targetSdkVersion : 29
minSdkVersion project.hasProperty('minSdkVersion') ? rootProject.ext.minSdkVersion : 22
targetSdkVersion project.hasProperty('targetSdkVersion') ? rootProject.ext.targetSdkVersion : 32
versionCode 1
versionName "1.0"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
Expand All @@ -47,7 +47,6 @@ android {

repositories {
google()
jcenter()
mavenCentral()
}

Expand All @@ -56,9 +55,9 @@ dependencies {
implementation 'androidx.multidex:multidex:2.0.1'
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation project(':capacitor-android')
implementation 'androidx.annotation:annotation:1.1.0'
implementation 'androidx.appcompat:appcompat:1.2.0'
implementation 'io.branch.sdk.android:library:5.2.0'
implementation 'androidx.annotation:annotation:1.4.0'
implementation 'androidx.appcompat:appcompat:1.5.0'
api 'io.branch.sdk.android:library:5.2.3'
testImplementation "junit:junit:$junitVersion"
androidTestImplementation "androidx.test.ext:junit:$androidxJunitVersion"
androidTestImplementation "androidx.test.espresso:espresso-core:$androidxEspressoCoreVersion"
Expand Down
2 changes: 1 addition & 1 deletion android/gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-5.6.4-all.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-7.4.2-all.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
6 changes: 3 additions & 3 deletions ios/Plugin.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -385,7 +385,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
MTL_ENABLE_DEBUG_INFO = YES;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
Expand Down Expand Up @@ -439,7 +439,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule";
Expand Down Expand Up @@ -487,7 +487,7 @@
DYLIB_INSTALL_NAME_BASE = "@rpath";
INFOPLIST_FILE = Plugin/Info.plist;
INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks $(FRAMEWORK_SEARCH_PATHS)";
ONLY_ACTIVE_ARCH = NO;
PRODUCT_BUNDLE_IDENTIFIER = com.getcapacitor.Plugin;
Expand Down
2 changes: 1 addition & 1 deletion ios/Plugin/Plugin.swift
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ public class BranchDeepLinks: CAPPlugin {
object: nil
)

Branch.getInstance().registerPluginName("Capacitor", version: "4.2.0")
Branch.getInstance().registerPluginName("Capacitor", version: "5.0.0")
}

@objc public func setBranchService(branchService: Any) {
Expand Down
2 changes: 1 addition & 1 deletion ios/Podfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
platform :ios, '12.0'
platform :ios, '13.0'

def capacitor_pods
use_frameworks!
Expand Down
10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "capacitor-branch-deep-links",
"version": "4.2.0",
"version": "5.0.0",
"description": "Capacitor plugin for Branch.io deep links",
"main": "dist/plugin.cjs.js",
"module": "dist/esm/index.js",
Expand All @@ -19,9 +19,9 @@
"author": "Bound State Software <[email protected]>",
"license": "MIT",
"devDependencies": {
"@capacitor/android": "^3.3.2",
"@capacitor/core": "^3.3.2",
"@capacitor/ios": "^3.3.2",
"@capacitor/android": "^4.0.1",
"@capacitor/core": "^4.0.1",
"@capacitor/ios": "^4.0.1",
"@ionic/prettier-config": "^1.0.0",
"@ionic/swiftlint-config": "^1.0.0",
"@rollup/plugin-node-resolve": "^8.1.0",
Expand All @@ -35,7 +35,7 @@
"typescript": "~3.8.3"
},
"peerDependencies": {
"@capacitor/core": "^3.3.2"
"@capacitor/core": "^4.0.1"
},
"files": [
"src/",
Expand Down

0 comments on commit d48d070

Please sign in to comment.