Skip to content

Instantly share code, notes, and snippets.

@BoxResin
Last active October 26, 2018 11:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save BoxResin/a072f16e72c08dc446de3307b218b99c to your computer and use it in GitHub Desktop.
Save BoxResin/a072f16e72c08dc446de3307b218b99c to your computer and use it in GitHub Desktop.
Android Library Startup
buildscript {
ext.kotlin_version = '1.2.71'
repositories {
google()
jcenter()
maven { url 'https://dl.bintray.com/minyushov/gradle' }
}
dependencies {
classpath 'com.android.tools.build:gradle:3.3.0-alpha13'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
// Bintray 업로더
classpath 'com.minyushov.gradle:bintray:1.1.0'
}
}
allprojects {
repositories {
google()
jcenter()
}
}
task clean(type: Delete) {
delete rootProject.buildDir
}
apply plugin: 'com.android.library'
apply plugin: 'kotlin-android'
apply plugin: 'com.minyushov.bintray'
// Bintray 업로드 설정
bintrayUpload {
// 패키지 정보
groupId = 'boxresin.android'
artifactId = 'core'
version = '0.2.1'
// Bintray 정보
repo = 'maven'
pkgName = 'boxresin.android:core'
vcsUrl = 'https://github.com/BoxResin/AndroidCore.git'
license = 'MIT'
// 기타
dryRun = false // Bintray 로 배포가 자동으로 되는 것을 막는다. (사이트에서 수동으로 승인해야 함)
docs = true
sources = true
// user 와 key 는 셸에서 입력
user = findProperty('user') ?: 'none'
key = findProperty('key') ?: 'none'
}
android {
compileSdkVersion 28
defaultConfig {
minSdkVersion 14
targetSdkVersion 28
testInstrumentationRunner 'androidx.test.runner.AndroidJUnitRunner'
}
}
// 의존성
dependencies {
// 로컬 JAR
implementation fileTree(dir: 'libs', include: ['*.jar'])
// 코틀린
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
// AndroidX
implementation 'androidx.appcompat:appcompat:1.0.0'
// 테스트
testImplementation 'junit:junit:4.12'
// 안드로이드 테스트
androidTestImplementation 'androidx.test:runner:1.1.0'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.1.0'
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment