18034727885
6 天以前 9ce248f0287e566b26fa73e795599ed27fdea24c
ChipsLayoutManager/build.gradle
@@ -1,33 +1,4 @@
plugins {
    id "com.jfrog.bintray" version "1.7.3"
    id "com.github.dcendents.android-maven" version "1.5"
}
apply plugin: 'com.android.library'
//upload settings to bintray
ext {
    bintrayRepo = 'widget'
    bintrayName = 'ChipsLayoutManager'
    libraryName = 'ChipsLayoutManager'
    publishedGroupId = 'com.beloo.widget'
    artifact = 'ChipsLayoutManager'
    libraryVersion = "rootProject.ext.libraryVersion"
    libraryDescription = 'Android. A custom layout manager for RecyclerView which mimicric TextView span behaviour, flow layouts behaviour with support of amazing recyclerView features'
    siteUrl = 'https://github.com/BelooS/ChipsLayoutManager'
    gitUrl = 'https://github.com/BelooS/ChipsLayoutManager.git'
    developerId = 'beloo'
    developerName = 'Beloy Oleg'
    developerEmail = 'beloyoleg@gmail.com'
    licenseName = 'The Apache Software License, Version 2.0'
    licenseUrl = 'http://www.apache.org/licenses/LICENSE-2.0.txt'
    allLicenses = ["Apache-2.0"]
}
android {
    compileSdkVersion 29
@@ -69,28 +40,6 @@
}
task androidJavadocs(type: Javadoc) {
    source = android.sourceSets.main.java.srcDirs
}
task androidJavadocsJar(type: Jar) {
    classifier = 'javadoc'
    baseName = artifact
    from androidJavadocs.destinationDir
}
task androidSourcesJar(type: Jar) {
    classifier = 'sources'
    baseName = artifact
    from android.sourceSets.main.java.srcDirs
}
artifacts {
    archives androidSourcesJar
    archives androidJavadocsJar
}
def supportVersion = "25+";
dependencies {
@@ -104,90 +53,4 @@
    androidTestCompile 'com.android.support.test:runner:0.5'
    androidTestCompile "com.android.support:support-annotations:$supportVersion"
    androidTestCompile 'pl.pragmatists:JUnitParams:1.0.5'
}
group = publishedGroupId // Maven Group ID for the artifact
version = libraryVersion
install {
    repositories.mavenInstaller {
        // This generates POM.xml with proper parameters
        pom {
            project {
                packaging 'aar'
                groupId publishedGroupId
                artifactId artifact
                version libraryVersion
                // Add your description here
                name libraryName
                description libraryDescription
                url siteUrl
                // Set your license
                licenses {
                    license {
                        name licenseName
                        url licenseUrl
                    }
                }
                developers {
                    developer {
                        id developerId
                        name developerName
                        email developerEmail
                    }
                }
                scm {
                    connection gitUrl
                    developerConnection gitUrl
                    url siteUrl
                }
            }.writeTo("$buildDir/poms/pom-default.xml")
        }
    }
}
Properties properties = new Properties()
properties.load(project.rootProject.file('local.properties').newDataInputStream())
bintray {
    user = properties.getProperty("bintray.user")
    key = properties.getProperty("bintray.apikey")
    configurations = ['archives'] //When uploading configuration files
    dryRun = false //[Default: false] Whether to run this as dry-run, without deploying
    publish = true //[Default: false] Whether version should be auto published after an upload
    override = true //[Default: false] Whether to override version artifacts already published
    //Package configuration. The plugin will use the repo and name properties to check if the package already exists. In that case, there's no need to configure the other package properties (like userOrg, desc, etc).
    pkg {
        repo = bintrayRepo
        name = bintrayName
        desc = libraryDescription
        websiteUrl = siteUrl
        issueTrackerUrl = 'https://github.com/BelooS/ChipsLayoutManager/issues'
        vcsUrl = gitUrl
        licenses = allLicenses
        publish = true
        publicDownloadNumbers = true
        githubRepo = 'BelooS/ChipsLayoutManager'
        githubReleaseNotesFile = 'README.md'
        //Optional version descriptor
        version {
            name = libraryVersion //Bintray logical version name
            desc = '' //Optional - Version-specific description'
            vcsTag = libraryVersion
            gpg {
                sign = true //Determines whether to GPG sign the files. The default is false
                passphrase = properties.getProperty("bintray.gpg.password")
                //Optional. The passphrase for GPG signing'
            }
        }
    }
}