Skip to content
This repository has been archived by the owner on Nov 28, 2023. It is now read-only.

Commit

Permalink
Merge pull request #11 from Adikteev/release/4.2.0
Browse files Browse the repository at this point in the history
release: 4.2.0
  • Loading branch information
atarafi authored Jun 12, 2023
2 parents 1752440 + e9d4ec3 commit f66b649
Show file tree
Hide file tree
Showing 5 changed files with 35 additions and 20 deletions.
7 changes: 3 additions & 4 deletions Assets/Plugins/Android/launcherTemplate.gradle
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
buildscript {
ext.kotlin_version = '1.6.20'
ext.kotlin_version = '1.8.0'

repositories {
google()
jcenter()
}

dependencies {
classpath 'com.android.tools.build:gradle:3.6.0'
classpath 'com.android.tools.build:gradle:4.2.2'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"

}
Expand Down Expand Up @@ -60,7 +60,6 @@ android {

buildTypes {
debug {
minifyEnabled **MINIFY_DEBUG**
proguardFiles getDefaultProguardFile('proguard-android.txt')**SIGNCONFIG**
jniDebuggable true
}
Expand All @@ -81,4 +80,4 @@ android {
enableSplit = true
}
}
}**SPLITS_VERSION_CODE****LAUNCHER_SOURCE_BUILD_SETUP**
}**SPLITS_VERSION_CODE****LAUNCHER_SOURCE_BUILD_SETUP**
9 changes: 3 additions & 6 deletions Assets/Plugins/Android/launcherTemplate2019.gradle
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
buildscript {
ext.kotlin_version = '1.6.20'
ext.kotlin_version = '1.8.0'

repositories {
google()
jcenter()
}

dependencies {
classpath 'com.android.tools.build:gradle:3.6.0'
classpath 'com.android.tools.build:gradle:4.2.2'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"

}
Expand Down Expand Up @@ -60,14 +60,11 @@ android {

buildTypes {
debug {
minifyEnabled **MINIFY_DEBUG**
useProguard **PROGUARD_DEBUG**
proguardFiles getDefaultProguardFile('proguard-android.txt')**SIGNCONFIG**
jniDebuggable true
}
release {
minifyEnabled **MINIFY_RELEASE**
useProguard **PROGUARD_RELEASE**
proguardFiles getDefaultProguardFile('proguard-android.txt')**SIGNCONFIG**
}
}**PACKAGING_OPTIONS****PLAY_ASSET_PACKS****SPLITS**
Expand All @@ -83,4 +80,4 @@ android {
enableSplit = true
}
}
}**SPLITS_VERSION_CODE****LAUNCHER_SOURCE_BUILD_SETUP**
}**SPLITS_VERSION_CODE****LAUNCHER_SOURCE_BUILD_SETUP**
6 changes: 3 additions & 3 deletions Assets/Plugins/Android/mainTemplate.gradle
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@

buildscript {
ext.kotlin_version = '1.6.20'
ext.kotlin_version = '1.8.0'

repositories {
google()
jcenter()
}

dependencies {
classpath 'com.android.tools.build:gradle:3.6.0'
classpath 'com.android.tools.build:gradle:4.2.2'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"

}
Expand Down Expand Up @@ -62,4 +62,4 @@ android {
}**REPOSITORIES**
**IL_CPP_BUILD_SETUP**
**SOURCE_BUILD_SETUP**
**EXTERNAL_SOURCES**
**EXTERNAL_SOURCES**
6 changes: 3 additions & 3 deletions Assets/Plugins/Android/mainTemplate2019.gradle
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@

buildscript {
ext.kotlin_version = '1.6.20'
ext.kotlin_version = '1.8.0'

repositories {
google()
jcenter()
}

dependencies {
classpath 'com.android.tools.build:gradle:3.6.0'
classpath 'com.android.tools.build:gradle:4.2.2'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"

}
Expand Down Expand Up @@ -59,4 +59,4 @@ android {
ignoreAssetsPattern = "!.svn:!.git:!.ds_store:!*.scc:.*:!CVS:!thumbs.db:!picasa.ini:!*~"
}**PACKAGING_OPTIONS**
}**REPOSITORIES****SOURCE_BUILD_SETUP**
**EXTERNAL_SOURCES**
**EXTERNAL_SOURCES**
27 changes: 23 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ CrossDK for Unity is available with iOS 11 minimal target version, but the `Cros

**Android API** version **>= API 21**

The Android version is using **Kotlin 1.6.20**, **Gradle 6.1.1** and **Gradle plugin 3.6.0**, it may conflict with other versions if you use some in your project.
The Android version is using **Kotlin 1.8.0**, **Gradle 6.8.3** and **Gradle plugin 4.2.2**

## Installation

Expand All @@ -35,7 +35,7 @@ If you already use CocoaPods in your Unity project, you should consider adding y
### Android using Github Packages

- You can download manually the CrossDK's release package `crossdk-android-X.X.X.aar` directly from
our [Github package registry page] (https://github.com/orgs/Adikteev/packages)
our [Github package registry page](https://github.com/Adikteev/crossdk-android/packages/1513405)
- Place the release package inside the folder `Assets\Plugins\Android`
- If you are using Unity 2019, you also need do delete the files `launcherTemplate.gradle` and `mainTemplate.gradle` in the folder `Assets\Plugins\Android` and to rename `launcherTemplate2019.gradle` to `launcherTemplate.gradle` and `mainTemplate2019.gradle` to `mainTemplate.gradle`.

Expand All @@ -45,7 +45,7 @@ To use CrossDK in your Unity project, you must download the `CrossDK.unitypackag

### Android specific configuration

- To make sure you are using Gradle 6.1.1, you can open the preferences menu (Edit > Preferences > External Tools) and set the Gradle path to a folder with Gradle 6.1.1 installed (you can download it here: https://gradle.org/releases/).
- Android sdk requires Gradle 6.8.3 or higher, you can open the preferences menu in the unity editor (Edit > Preferences > External Tools) and set the Gradle path to a folder with Gradle 6.8.3 or higher (you can download it here: https://gradle.org/releases/).
- If you are using Unity 2019, you also need to delete the files `launcherTemplate.gradle` and `mainTemplate.gradle` in the folder `Assets\Plugins\Android` and to rename `launcherTemplate2019.gradle` to `launcherTemplate.gradle` and `mainTemplate2019.gradle` to `mainTemplate.gradle`.

### Common configuration
Expand Down Expand Up @@ -187,6 +187,25 @@ public class CrossDKDelegatesSample : MonoBehaviour
}
}
```
You can check the [crossdk-ios](https://github.com/Adikteev/crossdk-ios) and the [crossdk-android](https://github.com/Adikteev/crossdk-android) repositories to know more about the available delegate for each platforms.
## Debug

You can enable logs for the cross promotion sdk by setting the log level to verbose, error or none using the following method:

```csharp
using UnityEngine;
using CrossDK;

void Awake()
{
CrossDKSingleton.SetDebugMode(DebugLevel.Verbose);
}
```
- `DebugLevel.Verbose`: for verbose logging
- `DebugLevel.Error`: for error logging
- `DebugLevel.None`: for disabling logger

> We recommend setting up this config before initializing the SDK.
You can check the [crossdk-ios](https://github.com/Adikteev/crossdk-ios) and the [crossdk-android](https://github.com/Adikteev/crossdk-android) repositories for more details.

That’s all you need to know!

0 comments on commit f66b649

Please sign in to comment.