Commit 95a1bbba authored by Ricki Hirner's avatar Ricki Hirner

Create Bintray package

parent 5ab5ddeb
Pipeline #42315301 passed with stage
in 4 minutes and 15 seconds
# Created by https://www.gitignore.io
### Android ###
# Built application files
*.apk
*.ap_
# Files for the Dalvik VM
*.dex
# Java class files
*.class
# Generated files
bin/
gen/
# Gradle files
.gradle/
build/
# Local configuration file (sdk path, etc)
local.properties
# Proguard folder generated by Eclipse
proguard/
# Log Files
*.log
### Intellij ###
# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm
*.iml
## Directory-based project format:
.idea/
# if you remove the above rule, at least ignore the following:
# User-specific stuff:
# .idea/workspace.xml
# .idea/tasks.xml
# .idea/dictionaries
# Sensitive or high-churn files:
# .idea/dataSources.ids
# .idea/dataSources.xml
# .idea/sqlDataSources.xml
# .idea/dynamic.xml
# .idea/uiDesigner.xml
# Gradle:
# .idea/gradle.xml
# .idea/libraries
# Mongo Explorer plugin:
# .idea/mongoSettings.xml
## File-based project format:
*.ipr
*.iws
## Plugin-specific files:
# IntelliJ
out/
# mpeltonen/sbt-idea plugin
.idea_modules/
# JIRA plugin
atlassian-ide-plugin.xml
# Crashlytics plugin (for Android Studio and IntelliJ)
com_crashlytics_export_strings.xml
crashlytics.properties
crashlytics-build.properties
### Gradle ###
.gradle
build/
gradle/
# Ignore Gradle GUI config
gradle-app.setting
gradle.properties
*.iml
*.log
### external libs ###
.svn
object Libs {
const val okhttpVersion = "3.12.1"
const val xpp3Version = "1.1.6"
}
import com.jfrog.bintray.gradle.BintrayExtension
import java.util.Date
import org.gradle.jvm.tasks.Jar
import org.jetbrains.dokka.gradle.DokkaTask
plugins {
kotlin("jvm") version "1.3.11"
id("com.github.kukuhyoniatmoko.buildconfigkotlin") version "1.0.5"
id("org.jetbrains.dokka") version "0.9.17"
`maven-publish`
id("com.jfrog.bintray") version "1.8.4"
}
object Libs {
val okhttpVersion = "3.12.1"
val xpp3Version = "1.1.6"
}
repositories {
......@@ -29,3 +36,60 @@ buildConfigKotlin {
buildConfig(name = "okhttpVersion", value = Libs.okhttpVersion)
})
}
group = "at.bitfire.dav4jvm"
version = "0.1"
val java: JavaPluginConvention = convention.getPluginByName("java")
val sourcesJar = task<Jar>("sourcesJar") {
classifier = "sources"
from(java.sourceSets.getByName("main").allSource)
}
val dokkaJar = task<Jar>("dokkaJar") {
dependsOn("dokka")
classifier = "javadoc"
from((tasks.getByName("dokka") as DokkaTask).outputDirectory)
}
publishing {
publications.invoke {
create<MavenPublication>("mavenJava") {
groupId = project.group.toString()
this.artifactId = artifactId
version = project.version.toString()
from(components["java"])
artifact(sourcesJar)
artifact(dokkaJar)
pom {
name.set("dav4jvm")
}
}
}
}
fun findProperty(s: String) = project.findProperty(s) as String?
bintray {
user = findProperty("bintrayUser")
key = findProperty("bintrayApiKey")
publish = true
setPublications("mavenJava")
setConfigurations("archives")
pkg(closureOf<BintrayExtension.PackageConfig> {
repo = "dav4jvm"
name = "dav4jvm"
desc = "WebDAV (including CalDAV, CardDAV) library for the Java virtual machine (Java/Kotlin)"
userOrg = "bitfireat"
websiteUrl = "https://gitlab.com/bitfireAT/dav4jvm"
issueTrackerUrl = "https://forums.bitfire.at/category/18/libraries"
vcsUrl = "https://gitlab.com/bitfireAT/dav4jvm.git"
setLicenses("MPL-2.0")
version(closureOf<BintrayExtension.VersionConfig> {
name = project.version.toString()
released = Date().toString()
})
})
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment