Skip to content

Commit

Permalink
Merge branch 'release/1.5.5'
Browse files Browse the repository at this point in the history
# Conflicts:
#	README.md
  • Loading branch information
Yurj Shmakov committed Jun 4, 2018
2 parents 13ae645 + 14c8300 commit 7e1cd88
Show file tree
Hide file tree
Showing 13 changed files with 413 additions and 403 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -35,4 +35,7 @@ Android Studio modile config file
captures/
.idea/

# Moxy artifacts
VERSION
artifacts/
artifacts-maven/
12 changes: 7 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,31 +76,33 @@ Base modules integration:
```groovy
dependencies {
...
compile 'com.arello-mobile:moxy:1.5.4'
annotationProcessor 'com.arello-mobile:moxy-compiler:1.5.4'
compile 'com.arello-mobile:moxy:1.5.5'
annotationProcessor 'com.arello-mobile:moxy-compiler:1.5.5'
}
```
For additional base view classes `MvpActivity` and `MvpFragment` add this:
```groovy
dependencies {
...
compile 'com.arello-mobile:moxy-android:1.5.4'
compile 'com.arello-mobile:moxy-android:1.5.5'
}
```
If you are planning to use AppCompat, then you can use `MvpAppCompatActivity` and `MvpAppCompatFragment`. Then add this:
```groovy
dependencies {
...
compile 'com.arello-mobile:moxy-app-compat:1.5.4'
compile 'com.arello-mobile:moxy-app-compat:1.5.5'
compile 'com.android.support:appcompat-v7:$support_version'
}
```
### Kotlin
If you are using kotlin, use `kapt` instead of `provided`/`apt` dependency type:
```groovy
apply plugin: 'kotlin-kapt'
dependencies {
...
kapt 'com.arello-mobile:moxy-compiler:1.5.4'
kapt 'com.arello-mobile:moxy-compiler:1.5.5'
}
```

Expand Down
7 changes: 3 additions & 4 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,7 @@ buildscript {
google()
}
dependencies {
classpath 'com.android.tools.build:gradle:3.0.0'
classpath 'me.tatarka:gradle-retrolambda:3.2.4'
classpath 'com.android.tools.build:gradle:3.1.2'
}
}

Expand All @@ -21,8 +20,8 @@ allprojects {
}

ext {
targetVersionCode = 44
targetVersionName = "1.5.4"
targetVersionCode = 45
targetVersionName = "1.5.5"

deps = [
android : 'com.google.android:android:1.6_r2',
Expand Down
4 changes: 2 additions & 2 deletions gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#Wed Sep 20 12:23:05 MSK 2017
#Tue Jun 05 00:53:30 NOVT 2018
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-4.1-all.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-4.4-all.zip
Empty file modified gradlew
100644 → 100755
Empty file.
160 changes: 81 additions & 79 deletions moxy-android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -46,18 +46,19 @@ task javadocJar(type: Jar, dependsOn: javadoc) {
}

task makeJar(type: Jar, dependsOn: classes) {
from('build/classes/main')
from('build/classes/java/main')
}

task copyVersion << {
task copyVersion {
doLast {
def versionFile = new File(project.rootDir, versionFile)
versionFile.write(targetVersionName)

def versionFile = new File(project.rootDir, versionFile)
versionFile.write(targetVersionName)

[publishDir, publishMavenDir].each { dest ->
copy {
from versionFile
into dest
[publishDir, publishMavenDir].each { dest ->
copy {
from versionFile
into dest
}
}
}
}
Expand Down Expand Up @@ -122,105 +123,106 @@ def getBasePom(String libName) {

}

task copyJars << {

def buildDir = 'build/libs/'
copy {
from buildDir
into publishMavenDir
}
task copyJars {
doLast {
def buildDir = 'build/libs/'
copy {
from buildDir
into publishMavenDir
}

copy {
from(buildDir)
{
rename targetArtefactId + '(.*)', targetArtefactIdDev + '$1'
}
into publishDir
copy {
from(buildDir)
{
rename targetArtefactId + '(.*)', targetArtefactIdDev + '$1'
}
into publishDir
}
}
}




task createPomXml << {

// creating local pom
task createPomXml {
doLast {
// creating local pom

getBasePom('moxy-dev').withXml {
asNode().appendNode('build').appendNode('plugins').with {
appendNode('plugin').with {
appendNode('groupId', 'org.apache.maven.plugins')
appendNode('artifactId', 'maven-gpg-plugin')
appendNode('version', '1.5')
appendNode('executions').with {
appendNode('execution').with {
appendNode('id', 'sign-artifacts')
appendNode('phase', 'verify')
appendNode('goals').with {
appendNode('goal', 'sign')
getBasePom('moxy-dev').withXml {
asNode().appendNode('build').appendNode('plugins').with {
appendNode('plugin').with {
appendNode('groupId', 'org.apache.maven.plugins')
appendNode('artifactId', 'maven-gpg-plugin')
appendNode('version', '1.5')
appendNode('executions').with {
appendNode('execution').with {
appendNode('id', 'sign-artifacts')
appendNode('phase', 'verify')
appendNode('goals').with {
appendNode('goal', 'sign')
}
}
}
appendNode('configuration').appendNode('gpgArguments').appendNode('arg', '--no-tty')
}
appendNode('configuration').appendNode('gpgArguments').appendNode('arg', '--no-tty')
}
}

asNode().artifactId*.value = targetArtefactIdDev
asNode().artifactId*.value = targetArtefactIdDev

asNode().dependencies.'*'.findAll() {
it.version.text() == '4.0.+' && project.configurations.compile.allDependencies.find { dep ->
dep.name == it.artifactId.text()
asNode().dependencies.'*'.findAll() {
it.version.text() == '4.0.+' && project.configurations.compile.allDependencies.find { dep ->
dep.name == it.artifactId.text()
}
}.each() {
it.version*.value = '[4.0,)'
}
}.each() {
it.version*.value = '[4.0,)'
}


}.writeTo(publishDir + "/" + targetArtefactIdDev + ".pom")
}.writeTo(publishDir + "/" + targetArtefactIdDev + ".pom")

//creating global pom
//creating global pom

getBasePom('moxy').withXml {
getBasePom('moxy').withXml {

asNode().appendNode('build')
.appendNode('plugins')
asNode().appendNode('build')
.appendNode('plugins')


}.writeTo(publishMavenDir + "/" + targetArtefactId + ".pom")
}.writeTo(publishMavenDir + "/" + targetArtefactId + ".pom")

getBasePom('moxy').withXml {
getBasePom('moxy').withXml {

asNode().appendNode('build')
.appendNode('plugins')
.appendNode('plugin')
.with {
appendNode('groupId', 'org.sonatype.plugins')
appendNode('artifactId', 'nexus-staging-maven-plugin')
appendNode('version', '1.6.4')
appendNode('extensions', 'true')
appendNode('configuration').with {
appendNode('serverId', 'ossrh')
appendNode('nexusUrl', 'https://oss.sonatype.org/')
appendNode('autoReleaseAfterClose', 'false')
}
}

asNode().appendNode('distributionManagement').with {
appendNode('snapshotRepository')
.with {
appendNode('id', 'ossrh')
appendNode('url', 'https://oss.sonatype.org/content/repositories/snapshots')
}
appendNode('repository')
asNode().appendNode('build')
.appendNode('plugins')
.appendNode('plugin')
.with {
appendNode('id', 'ossrh')
appendNode('url', 'https://oss.sonatype.org/service/local/staging/deploy/maven2/')
appendNode('groupId', 'org.sonatype.plugins')
appendNode('artifactId', 'nexus-staging-maven-plugin')
appendNode('version', '1.6.4')
appendNode('extensions', 'true')
appendNode('configuration').with {
appendNode('serverId', 'ossrh')
appendNode('nexusUrl', 'https://oss.sonatype.org/')
appendNode('autoReleaseAfterClose', 'false')
}
}
}

}.writeTo(publishMavenDir + "/pom.xml")
asNode().appendNode('distributionManagement').with {
appendNode('snapshotRepository')
.with {
appendNode('id', 'ossrh')
appendNode('url', 'https://oss.sonatype.org/content/repositories/snapshots')
}
appendNode('repository')
.with {
appendNode('id', 'ossrh')
appendNode('url', 'https://oss.sonatype.org/service/local/staging/deploy/maven2/')
}
}

}.writeTo(publishMavenDir + "/pom.xml")

}
}

compileJava.dependsOn clearPublishDir
Expand Down
Loading

0 comments on commit 7e1cd88

Please sign in to comment.