Skip to content

Commit 38cbcf7

Browse files
Android SDK v3.12.4 | Issue in dependencies download from Maven
1 parent 2932dec commit 38cbcf7

File tree

13 files changed

+310
-415
lines changed

13 files changed

+310
-415
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -261,7 +261,7 @@ You can use advanced sync queries to fetch custom results while performing initi
261261

262262
### The MIT License (MIT)
263263

264-
Copyright © 2012-2023 [Contentstack](https://www.contentstack.com/). All Rights Reserved
264+
Copyright © 2012-2024 [Contentstack](https://www.contentstack.com/). All Rights Reserved
265265

266266
Permission is hereby granted, free of charge, to any person obtaining a copy of this software
267267
and associated documentation files (the "Software"), to deal in the Software without restriction,

SECURITY.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
## Security
1+
# Security
22

33
Contentstack takes the security of our software products and services seriously, which includes all source code repositories managed through our GitHub organizations.
44

@@ -14,14 +14,14 @@ You should receive a response within 24 hours. If for some reason you do not, pl
1414

1515
Please include the requested information listed below (as much as you can provide) to help us better understand the nature and scope of the possible issue:
1616

17-
* Type of issue (e.g. buffer overflow, SQL injection, cross-site scripting, etc.)
18-
* Full paths of source file(s) related to the manifestation of the issue
19-
* The location of the affected source code (tag/branch/commit or direct URL)
20-
* Any special configuration required to reproduce the issue
21-
* Step-by-step instructions to reproduce the issue
22-
* Proof-of-concept or exploit code (if possible)
23-
* Impact of the issue, including how an attacker might exploit the issue
17+
- Type of issue (e.g. buffer overflow, SQL injection, cross-site scripting, etc.)
18+
- Full paths of source file(s) related to the manifestation of the issue
19+
- The location of the affected source code (tag/branch/commit or direct URL)
20+
- Any special configuration required to reproduce the issue
21+
- Step-by-step instructions to reproduce the issue
22+
- Proof-of-concept or exploit code (if possible)
23+
- Impact of the issue, including how an attacker might exploit the issue
2424

2525
This information will help us triage your report more quickly.
2626

27-
[https://www.contentstack.com/trust/](https://www.contentstack.com/trust/)
27+
[https://www.contentstack.com/trust/](https://www.contentstack.com/trust/)

build.gradle

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,23 @@
11
buildscript {
2-
ext.jacoco_version = '0.8.8'
2+
ext {
3+
jacoco_version = '0.8.8'
4+
agp_version = '8.2.1'
5+
}
36
repositories {
47
maven {
5-
url = uri("https://storage.googleapis.com/r8-releases/raw")
68
url "https://plugins.gradle.org/m2/"
79
}
810
google()
911
mavenCentral()
1012
}
1113

1214
dependencies {
13-
classpath "com.android.tools.build:gradle:7.2.2" //7.0.4
14-
classpath 'io.github.gradle-nexus:publish-plugin:1.1.0'
15+
classpath "com.android.tools.build:gradle:8.2.1" //8.2.1
16+
classpath 'io.github.gradle-nexus:publish-plugin:2.0.0-rc-1'
1517
classpath "org.jacoco:org.jacoco.core:$jacoco_version"
16-
classpath "com.android.tools:r8:8.1.56"
1718
}
1819
}
1920

20-
apply plugin: 'io.github.gradle-nexus.publish-plugin'
21-
apply from: "${rootDir}/scripts/publish-root.gradle"
22-
2321
tasks.register('clean', Delete) {
2422
delete rootProject.buildDir
2523
}

contentstack/build.gradle

Lines changed: 57 additions & 100 deletions
Original file line numberDiff line numberDiff line change
@@ -1,96 +1,59 @@
11
plugins {
2-
id 'signing'
3-
id 'maven-publish'
4-
id 'com.android.library'
5-
id 'jacoco'
2+
id "com.vanniktech.maven.publish" version "0.27.0"
3+
id "com.android.library"
64
}
75

8-
def localProperties = new Properties()
9-
localProperties.load(new FileInputStream(rootProject.file("local.properties")))
6+
import com.vanniktech.maven.publish.SonatypeHost
7+
android.buildFeatures.buildConfig true
108

11-
group = 'com.contentstack.sdk'
12-
version = '3.12.4-SNAPSHOT'
9+
mavenPublishing {
10+
publishToMavenCentral(SonatypeHost.DEFAULT)
11+
signAllPublications()
12+
coordinates("com.contentstack.sdk", "android", "3.12.4-rc2-SNAPSHOT")
1313

14-
15-
//publishing {
16-
// publications {
17-
// mavenJava(MavenPublication) {
18-
// artifactId = 'android'
19-
// versionMapping {
20-
// usage('java-api') {
21-
// fromResolutionOf('runtimeClasspath')
22-
// }
23-
// usage('java-runtime') {
24-
// fromResolutionResult()
25-
// }
26-
// }
27-
// pom {
28-
//
29-
// name = 'contentstack-android'
30-
// packaging 'aar'
31-
// artifactId "android"
32-
// description = 'Android SDK for Contentstack Content Delivery API, Contentstack is a headless CMS with an API-first approach'
33-
// url = 'https://github.com/contentstack/contentstack-android'
34-
//
35-
// scm {
36-
// url 'https://github.com/contentstack/contentstack-android/'
37-
// connection 'scm:git@github.com:contentstack/contentstack-android'
38-
// developerConnection 'scm:git@github.com:contentstack/contentstack-android.git'
39-
// }
40-
//
41-
// licenses {
42-
// license {
43-
// name 'The MIT License'
44-
// url 'http://www.opensource.org/licenses/mit-license.php'
45-
// distribution 'repo'
46-
// }
47-
// }
48-
// developers {
49-
// developer {
50-
// id 'ishaileshmishra'
51-
// name 'Shailesh Mishra'
52-
// email 'mobile@contentstack.com'
53-
// }
54-
// }
55-
// }
56-
// }
57-
// }
58-
// repositories {
59-
// maven {
60-
// def releasesRepoUrl = layout.buildDirectory.dir('repos/releases')
61-
// def snapshotsRepoUrl = layout.buildDirectory.dir('repos/snapshots')
62-
// url = version.endsWith('SNAPSHOT') ? snapshotsRepoUrl : releasesRepoUrl
63-
// }
64-
// }
65-
//}
66-
67-
//signing {
68-
// sign publishing.publications.mavenJava
69-
//}
70-
71-
72-
//javadoc {
73-
// if (JavaVersion.current().isJava9Compatible()) {
74-
// options.addBooleanOption('html5', true)
75-
// }
76-
//}
14+
pom {
15+
name = "contentstack-android"
16+
description = "The Content Delivery SDK facilitates the retrieval of content from your Contentstack account, enabling seamless delivery to your web or mobile properties.."
17+
inceptionYear = "2018"
18+
url = "https://github.com/contentstack/contentstack-android"
19+
licenses {
20+
license {
21+
name = "The MIT License"
22+
url = "https://github.com/contentstack/contentstack-android/blob/master/LICENSE"
23+
distribution = "https://github.com/contentstack/contentstack-android/blob/master/LICENSE"
24+
}
25+
}
26+
developers {
27+
developer {
28+
id = "ishaileshmishra"
29+
name = "contentstack"
30+
url = "https://github.com/contentstack/contentstack-android"
31+
}
32+
}
33+
scm {
34+
url = "scm:git@github.com:contentstack/contentstack-android"
35+
connection = "scm:git:git://github.com/username/mylibrary.git"
36+
developerConnection = "scm:git@github.com:contentstack/contentstack-android.git"
37+
}
38+
}
39+
}
7740

7841

7942
tasks.register('jacocoTestReport', JacocoReport) {
80-
// dependsOn['testDebugUnitTest', 'createDebugCoverageReport']
43+
dependsOn['testDebugUnitTest', 'createDebugCoverageReport']
8144
reports {
8245
html.enabled = true
8346
}
84-
85-
// afterEvaluate {
86-
// classDirectories.setFrom(files(classDirectories.files.collect {
87-
// fileTree(dir: it, exclude: '**com/contentstack/okhttp**')
88-
// fileTree(dir: it, exclude: '**com/contentstack/okio**')
89-
// fileTree(dir: it, exclude: '**com/contentstack/txtmark**')
90-
// }))
91-
// }
47+
afterEvaluate {
48+
classDirectories.setFrom(files(classDirectories.files.collect {
49+
fileTree(dir: it, exclude: '**com/contentstack/okhttp**')
50+
fileTree(dir: it, exclude: '**com/contentstack/okio**')
51+
fileTree(dir: it, exclude: '**com/contentstack/txtmark**')
52+
}))
53+
}
9254
}
9355
android {
56+
namespace "com.contentstack.sdk"
9457
packagingOptions {
9558
exclude 'META-INF/DEPENDENCIES'
9659
exclude 'META-INF/LICENSE.md'
@@ -102,6 +65,7 @@ android {
10265
exclude 'META-INF/ASL2.0'
10366
exclude("META-INF/*.kotlin_module")
10467
}
68+
10569
testOptions {
10670
unitTests.all {
10771
jacoco {
@@ -125,6 +89,7 @@ android {
12589
}
12690
compileSdk 26
12791
defaultConfig {
92+
multiDexEnabled true
12893
minSdkVersion 19
12994
versionCode 1
13095
versionName "1.0"
@@ -133,14 +98,17 @@ android {
13398
signingConfig signingConfigs.release
13499
}
135100

101+
102+
def localProperties = new Properties()
103+
localProperties.load(new FileInputStream(rootProject.file("local.properties")))
136104
buildTypes {
137105
debug {
138106
debuggable true
139107
testCoverageEnabled true
140108
buildConfigField "String", "host", localProperties['host']
141109
buildConfigField "String", "APIKey", localProperties['APIKey']
142110
buildConfigField "String", "deliveryToken", localProperties['deliveryToken']
143-
buildConfigField "String", "environment", localProperties['env']
111+
buildConfigField "String", "environment", localProperties['environment']
144112
buildConfigField "String", "contentTypeUID", localProperties['contentType']
145113
buildConfigField "String", "assetUID", localProperties['assetUid']
146114
}
@@ -149,38 +117,32 @@ android {
149117
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
150118
}
151119
}
152-
flavorDimensions "default"
120+
//flavorDimensions "default"
153121
lintOptions { abortOnError false }
154122
compileOptions {
123+
//coreLibraryDesugaringEnabled true
155124
sourceCompatibility JavaVersion.VERSION_1_8
156125
targetCompatibility JavaVersion.VERSION_1_8
157126
}
158127
}
159-
repositories {
160-
// flatDir { dirs 'libs' }
161-
// mavenCentral()
162-
// mavenLocal()
163-
}
164-
165128
configurations { archives }
166-
167129
dependencies {
130+
def multidex_version = "2.0.1"
168131
configurations.configureEach { resolutionStrategy.force 'com.android.support:support-annotations:23.1.0' }
169132
implementation fileTree(include: ['*.jar'], dir: 'libs')
170133
implementation 'com.contentstack.sdk:utils:1.2.6'
171-
// implementation 'com.android.support:appcompat-v7:26.1.0'
172-
// implementation 'com.android.support:support-v4:26.1.0'
173134
implementation 'com.android.volley:volley:1.2.1'
174135
implementation 'junit:junit:4.13.2'
175-
testImplementation 'junit:junit:4.13.2'
176-
androidTestImplementation 'androidx.test:core:1.5.0'
177136
coreLibraryDesugaring 'com.android.tools:desugar_jdk_libs:2.0.4'
137+
implementation "androidx.multidex:multidex:$multidex_version"
178138

139+
testImplementation 'junit:junit:4.13.2'
140+
androidTestImplementation 'androidx.test:core:1.5.0'
179141
androidTestImplementation('com.android.support.test.espresso:espresso-core:3.0.2', {
180142
exclude group: 'com.android.support', module: 'support-annotations'
181143
})
182144
}
183-
tasks.register('clearJar', Delete) { delete 'build/libs/Contentstack.jar' }
145+
tasks.register('clearJar', Delete) { delete 'build/libs/contentstack.jar' }
184146
tasks.register('unzip', Copy) {
185147
def zipFile = file('build/intermediates/intermediate-jars/release/classes.jar')
186148
def outputDir = file("${buildDir}/contentstack-jar")
@@ -191,11 +153,6 @@ tasks.register('createJar', Jar) {
191153
archivesBaseName = "contentstack.jar"
192154
from('build/contentstack-jar/')
193155
include 'com/contentstack/'
194-
include 'META-INF/'
156+
//include 'META-INF/'
195157
}
196158
createJar.dependsOn(clearJar, unzip, build)
197-
198-
java {
199-
sourceCompatibility = JavaVersion.VERSION_1_8
200-
targetCompatibility = JavaVersion.VERSION_1_8
201-
}

contentstack/src/androidTest/java/com/contentstack/sdk/AssetTestCase.java

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
package com.contentstack.sdk;
2-
32
import android.content.Context;
3+
import android.support.test.InstrumentationRegistry;
44
import android.util.Log;
55

66
import org.junit.BeforeClass;
@@ -13,10 +13,8 @@
1313
import static junit.framework.Assert.assertTrue;
1414
import static junit.framework.TestCase.assertEquals;
1515

16-
import androidx.test.InstrumentationRegistry;
1716
import androidx.test.core.app.ApplicationProvider;
1817

19-
2018
@FixMethodOrder(MethodSorters.NAME_ASCENDING)
2119
public class AssetTestCase {
2220

contentstack/src/androidTest/java/com/contentstack/sdk/ExampleInstrumentedTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@
44
import static org.junit.Assert.assertNotNull;
55

66
import android.content.Context;
7+
import android.support.test.internal.runner.junit4.AndroidJUnit4ClassRunner;
78
import android.util.Log;
89

910
import androidx.test.core.app.ApplicationProvider;
10-
import androidx.test.internal.runner.junit4.AndroidJUnit4ClassRunner;
1111

1212
import org.junit.Test;
1313
import org.junit.runner.RunWith;

contentstack/src/androidTest/java/com/contentstack/sdk/QueryTestCase.java

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
package com.contentstack.sdk;
22

3-
import android.content.Context;
43
import android.util.Log;
54

65
import org.json.JSONArray;
@@ -13,9 +12,6 @@
1312

1413
import static junit.framework.TestCase.assertEquals;
1514

16-
import androidx.test.InstrumentationRegistry;
17-
import androidx.test.core.app.ApplicationProvider;
18-
1915

2016
public class QueryTestCase {
2117

gradle/wrapper/gradle-wrapper.jar

13.2 KB
Binary file not shown.
Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
#Tue Dec 13 11:19:51 IST 2022
2-
#gradle-7.6-bin.zip
31
distributionBase=GRADLE_USER_HOME
4-
distributionUrl=https\://services.gradle.org/distributions/gradle-7.6.1-bin.zip
52
distributionPath=wrapper/dists
6-
zipStorePath=wrapper/dists
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.2.1-bin.zip
4+
networkTimeout=10000
5+
validateDistributionUrl=true
76
zipStoreBase=GRADLE_USER_HOME
7+
zipStorePath=wrapper/dists

0 commit comments

Comments
 (0)