Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
…rapper

Update version to ensure that the minSDK is set to 19 in the jitpack build.
  • Loading branch information
ltrudu committed Nov 7, 2022
2 parents 1a583fc + 7d5775f commit 37910f8
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 64 deletions.
55 changes: 2 additions & 53 deletions DeviceIdentifiersWrapper/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ android {
defaultConfig {
minSdkVersion 19
targetSdkVersion 32
versionCode 5
versionName "0.5"
versionCode 6
versionName "0.6"

testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"

Expand All @@ -40,54 +40,3 @@ dependencies {
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
compileOnly 'com.symbol:emdk:+'
}

/*
Generate release files for publication and Zip them
https://medium.com/@daniellevass/how-to-publish-your-android-studio-library-to-jcenter-5384172c4739
https://raw.githubusercontent.com/blundell/release-android-library/master/android-release-aar.gradle
*/

// ./gradlew clean build generateRelease
apply plugin: 'maven'

def version = project.PUBLISH_VERSION

def localReleaseDest = "${buildDir}/release/${version}"

task androidJavadocs(type: Javadoc) {
failOnError = false
source = android.sourceSets.main.java.srcDirs
ext.androidJar = "${android.sdkDirectory}/platforms/${android.compileSdkVersion}/android.jar"
classpath += files(ext.androidJar)
}

task androidJavadocsJar(type: Jar, dependsOn: androidJavadocs) {
archiveClassifier = 'javadoc'
from androidJavadocs.destinationDir
}

task androidSourcesJar(type: Jar) {
archiveClassifier = 'sources'
from android.sourceSets.main.java.srcDirs
}

task zipRelease(type: Zip) {
from localReleaseDest
destinationDir buildDir
archiveBaseName = "release-${version}"
}

task generateRelease {
doLast {
println "Release ${version} can be found at ${localReleaseDest}/"
println "Release ${version} zipped can be found ${buildDir}/release-${version}.zip"
}
}

generateRelease.dependsOn(zipRelease)


artifacts {
archives androidSourcesJar
archives androidJavadocsJar
}
22 changes: 11 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,14 @@
## Sample Repository
https://github.com/ltrudu/DeviceIdentifiersWrapper-Sample

## V0.4 : Basic cache mechanism
## V0.4 : Basic cache mechanism & Wait for EMDK availability
```text
Added basic cache mechanism.
The IMei and the Serial number will be cached once they get retrieved.
The cache can be reset with the method:
DIHelper.resetCachedValues()
Added a mechanism to wait for the EMDK if it is not available (when responding to the BOOT_COMPLETED event for ex.
To be tested... feel free to report any issue regarding this feature.
The IMei and the Serial number will be cached once they get retrieved.
The cache can be reset with the method:
DIHelper.resetCachedValues()
Added a mechanism to wait for the EMDK if it is not available (when responding to the BOOT_COMPLETED event for ex.)
To be tested... feel free to report any issue regarding this feature.
```
## V0.3 : Update for A11
```text
Expand All @@ -34,11 +34,11 @@ https://github.com/ltrudu/DeviceIdentifiersWrapper-Sample
## Important !!
```text
Due to usage of the EMDK and the need to register the application, it is strongly advised to call the methods in your application class
Check https://github.com/ltrudu/DeviceIdentifiersWrapper-Sample implementation.
It's a basic implementation using static members.
Feel free to remove statics and replace them with a better code in terms of architecture.
The goal was to pass the idea that theses number should be retrieved only once, and the best place for it is the Application class.
Note that a mechanism has been added in V0.4 to wait for the EMDK in case it would not be available (the classic use case is when your app respond to the BOOT_COMPLETED event that occurs way before the EMDK finishes its initialization)
Check https://github.com/ltrudu/DeviceIdentifiersWrapper-Sample implementation.
It's a basic implementation using static members.
Feel free to remove statics and replace them with a better code in terms of architecture.
The goal was to pass the idea that theses number should be retrieved only once, and the best place for it is the Application class.
Note that a mechanism has been added in V0.4 to wait for the EMDK in case it would not be available (the classic use case is when your app respond to the BOOT_COMPLETED event that occurs way before the EMDK finishes its initialization)
```

## Description
Expand Down

0 comments on commit 37910f8

Please sign in to comment.