Kotlinで作ったAndroidのライブラリを5分でjitpack.ioに公開する

## AndroidManifest.xmlからapplicationを削除
## `setting.gradle` に ArtifactIdを設定
```
include ':lib'
rootProject.name = 'libname'
```

## 諸々テンプレファイルを追加

```:PROJECT_ROOT/LICENSE
The MIT License (MIT)

Copyright (c) 2016 Your Name

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
```

```md:README.md
# Project
jitpack.ioのバッジ

## Installation
jitpack.ioからコピペ

## LISENCE
see [LISENCE](./LISENCE)
```

```groovy:PROJECT_ROOT/build.gradle
// Top-level build file where you can add configuration options common to all sub-projects/modules.

buildscript {
    repositories {
        jcenter()
    }
    dependencies {
        classpath 'com.android.tools.build:gradle:2.1.0'
        classpath 'com.github.dcendents:android-maven-gradle-plugin:1.3'
        // NOTE: Do not place your application dependencies here; they belong
        // in the individual module build.gradle files
    }
}

allprojects {
    repositories {
        jcenter()
    }
}

task clean(type: Delete) {
    delete rootProject.buildDir
}
```

```groovy:lib/build.gradle
buildscript {
    ext {
        kotlin_version = "1.0.1-2"
    }
    dependencies {
        classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
    }
}

plugins {
    id 'pl.allegro.tech.build.axion-release' version '1.3.4'
}

apply plugin: 'com.android.library'
apply plugin: 'android-maven'
apply plugin: 'kotlin-android'

project.version = scmVersion.version
group='com.github.unhappychoice'

scmVersion {
    tag {
        prefix = ''
    }
}

android {
    compileSdkVersion 23
    buildToolsVersion '23.0.3'

    defaultConfig {
        minSdkVersion 15
        targetSdkVersion 23
        versionCode 1
        versionName "1.0"
    }
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }
    }
    sourceSets {
        main.java.srcDirs += 'src/main/kotlin'
    }
}

dependencies {
    compile fileTree(include: ['*.jar'], dir: 'libs')
    testCompile 'junit:junit:4.12'
    compile 'com.android.support:appcompat-v7:23.3.0'
    compile 'com.android.support:design:23.3.0'
    compile "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
}
```

## 公開

```bash
git commit -m 'final commit before publish version'
./gradlew release
```

## Jitpack.ioで確認

[Jitpack.io](https://jitpack.io)

## テスト

```groovy

allprojects {
    repositories {
        maven { url "https://jitpack.io" }
    }
}
dependencies {
    compile 'com.github.your_github_id:artifactid:0.1.0'
}
```