Skip to content

Commit 72e6002

Browse files
authored
Merge pull request #7 from rnpy/release1.1
Release 1.1
2 parents b8654fe + 5275bb0 commit 72e6002

File tree

7 files changed

+25
-39
lines changed

7 files changed

+25
-39
lines changed

CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@ Change Log
33

44
## Version 1.1
55

6+
* update gradle plugin to 5.1
7+
* update dependencies
8+
* simplify publishing
69
* Fix wrong attr id being used for shimmer center width
710
* Add ability to set ShimmerLayout style with theme attribute
811

app/build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ dependencies {
3838
implementation fileTree(dir: 'libs', include: ['*.jar'])
3939
implementation "com.android.support:appcompat-v7:$android_support_version"
4040
implementation "com.android.support:recyclerview-v7:$android_support_version"
41-
implementation "org.jetbrains.kotlin:kotlin-stdlib-jre7:$kotlin_version"
41+
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
4242
implementation project(':shimmerlayout')
4343

4444
implementation "com.trello.rxlifecycle2:rxlifecycle-kotlin:$rxlifecycle2_version"
@@ -49,7 +49,7 @@ dependencies {
4949
implementation "io.reactivex.rxjava2:rxjava:$rxjava_version"
5050
}
5151
repositories {
52-
mavenCentral()
52+
jcenter()
5353
maven {
5454
url "https://maven.google.com"
5555
}

app/src/main/java/xyz/peridy/shimmerdemo/MainActivity.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ class MainActivity : RxActivity() {
6060
val imageView: ImageView = itemView.findViewById(R.id.image_view)
6161
}
6262

63-
override fun onViewRecycled(holder: RecyclerView.ViewHolder?) {
63+
override fun onViewRecycled(holder: RecyclerView.ViewHolder) {
6464
(holder as? LoadingViewHolder)?.shimmerLayout?.visibility = View.GONE
6565
super.onViewRecycled(holder)
6666
}

common.gradle

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,17 +5,17 @@ ext.scm = 'https://github.com/rnpy/ShimmerLayout.git'
55
ext.description = 'Simple, memory efficient and high performance Shimmer Layout for Android.'
66

77
ext.minSdk = 15
8-
ext.compileSdk = 26
9-
ext.buildTools = "26.0.2"
10-
ext.kotlin_version = '1.2.21'
11-
ext.bintray_version = '1.7.3'
12-
ext.gradle_version = '3.0.1'
13-
ext.android_support_version = '27.0.2'
8+
ext.compileSdk = 28
9+
ext.buildTools = "28.0.3"
10+
ext.kotlin_version = '1.3.31'
11+
ext.bintray_version = '1.8.4'
12+
ext.gradle_version = '3.4.1'
13+
ext.android_support_version = '28.0.0'
1414
ext.maven_gradle_plugin_version = '2.0'
1515
ext.dexcount_version = '0.8.2'
1616

1717
// Demo app
1818
ext.rxlifecycle2_version = '2.2.0'
1919
ext.google_play_services_version = '11.4.0'
20-
ext.rxandroid_version = '2.0.1'
20+
ext.rxandroid_version = '2.1.1'
2121
ext.rxjava_version = '2.1.5'
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
#Fri Feb 16 09:16:16 NZDT 2018
1+
#Mon May 27 13:39:29 NZST 2019
22
distributionBase=GRADLE_USER_HOME
33
distributionPath=wrapper/dists
44
zipStoreBase=GRADLE_USER_HOME
55
zipStorePath=wrapper/dists
6-
distributionUrl=https\://services.gradle.org/distributions/gradle-4.1-all.zip
6+
distributionUrl=https\://services.gradle.org/distributions/gradle-5.1.1-all.zip

publishing.gradle

Lines changed: 8 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,7 @@
11
apply plugin: 'maven-publish'
22
apply plugin: 'com.jfrog.bintray'
33

4-
project.afterEvaluate {
5-
if (project.plugins.hasPlugin("com.android.library")) {
6-
project.android.libraryVariants.all { variant ->
7-
variant.getOutputs().all { output ->
8-
outputFileName = new File("${project.name}-v${project.version}.aar")
9-
}
10-
}
11-
}
12-
}
13-
14-
project.group = project.ext.group
15-
project.version = project.ext.version
16-
4+
// To publish a new version, set BINTRAY_USERNAME and BINTRAY_API_KEY, then run "clean build bintrayUpload"
175
bintray {
186
user = BINTRAY_USERNAME
197
key = BINTRAY_API_KEY
@@ -23,10 +11,10 @@ bintray {
2311
licenses = ['BSD 2-Clause']
2412
vcsUrl = project.ext.scm
2513
version {
26-
name = project.version
14+
name = project.ext.version
2715
desc = project.ext.description
2816
released = new Date()
29-
vcsTag = project.version
17+
vcsTag = project.ext.version
3018
}
3119
publications = ['Bintray']
3220
}
@@ -61,7 +49,7 @@ publishing.publications {
6149
version project.ext.version
6250

6351
artifact sourceJar
64-
artifact "$buildDir/outputs/aar/${project.name}-v${project.version}.aar"
52+
artifact "$buildDir/outputs/aar/${project.name}-release.aar"
6553

6654
//generate pom nodes for dependencies
6755
//when a project references another project, it's artifact node is generated
@@ -91,21 +79,16 @@ publishing.publications {
9179
}
9280

9381
def getArtifactId() {
94-
return getArtifactId(project)
95-
96-
}
97-
98-
def getArtifactId(someProject) {
99-
if (!someProject.ext.has('artifactId')) {
82+
if (!project.ext.has('artifactId')) {
10083
//default artifactId is the project/module name
101-
return someProject.getName()
84+
return project.getName()
10285

10386
}
104-
return someProject.ext.artifactId
87+
return project.ext.artifactId
10588
}
10689

10790

108-
def addDependencyNodeToPom(dependenciesNode, group, artifact, version) {
91+
static def addDependencyNodeToPom(dependenciesNode, group, artifact, version) {
10992
def dependencyNode = dependenciesNode.appendNode('dependency')
11093
dependencyNode.appendNode("groupId", group)
11194
dependencyNode.appendNode("artifactId", artifact)

shimmerlayout/build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,11 +39,11 @@ android {
3939

4040
dependencies {
4141
implementation fileTree(dir: 'libs', include: ['*.jar'])
42-
implementation "org.jetbrains.kotlin:kotlin-stdlib-jre7:$kotlin_version"
42+
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
4343
}
4444

4545
repositories {
46-
mavenCentral()
46+
jcenter()
4747
maven {
4848
url "https://maven.google.com"
4949
}

0 commit comments

Comments
 (0)