Sergey Vasilinets | 4e97056 | 2019-12-12 13:39:19 +0000 | [diff] [blame] | 1 | /* |
| 2 | * Copyright 2019 The Android Open Source Project |
| 3 | * |
| 4 | * Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | * you may not use this file except in compliance with the License. |
| 6 | * You may obtain a copy of the License at |
| 7 | * |
| 8 | * http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | * |
| 10 | * Unless required by applicable law or agreed to in writing, software |
| 11 | * distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | * See the License for the specific language governing permissions and |
| 14 | * limitations under the License. |
| 15 | */ |
| 16 | |
| 17 | import androidx.build.CompilationTarget |
| 18 | import androidx.build.LibraryGroups |
| 19 | import androidx.build.LibraryVersions |
| 20 | import androidx.build.Publish |
Sergey Vasilinets | 511969f | 2020-01-09 12:52:23 +0000 | [diff] [blame] | 21 | import androidx.build.SdkResourceGenerator |
Sergey Vasilinets | 4e97056 | 2019-12-12 13:39:19 +0000 | [diff] [blame] | 22 | |
| 23 | import static androidx.build.dependencies.DependenciesKt.* |
| 24 | |
| 25 | plugins { |
| 26 | id("AndroidXPlugin") |
| 27 | id("kotlin") |
| 28 | id("java-gradle-plugin") |
| 29 | } |
| 30 | |
Sergey Vasilinets | 511969f | 2020-01-09 12:52:23 +0000 | [diff] [blame] | 31 | SdkResourceGenerator.generateForHostTest(project) |
Sergey Vasilinets | 95f91db | 2020-01-13 20:21:29 +0000 | [diff] [blame] | 32 | apply from: "../../buildSrc/kotlin-dsl-dependency.gradle" |
Sergey Vasilinets | 511969f | 2020-01-09 12:52:23 +0000 | [diff] [blame] | 33 | |
Sergey Vasilinets | 4e97056 | 2019-12-12 13:39:19 +0000 | [diff] [blame] | 34 | dependencies { |
Sergey Vasilinets | 95f91db | 2020-01-13 20:21:29 +0000 | [diff] [blame] | 35 | implementation findGradleKotlinDsl() |
Sergey Vasilinets | 4e97056 | 2019-12-12 13:39:19 +0000 | [diff] [blame] | 36 | implementation gradleApi() |
| 37 | implementation(AGP_STABLE) |
| 38 | implementation(KOTLIN_STDLIB) |
Aurimas Liutikas | 7531105 | 2020-10-01 16:45:02 -0700 | [diff] [blame] | 39 | implementation("gradle.plugin.com.google.protobuf:protobuf-gradle-plugin:0.8.13") |
Sergey Vasilinets | 0e965b8 | 2020-02-04 11:43:47 +0000 | [diff] [blame] | 40 | implementation("org.anarres.jarjar:jarjar-gradle:1.0.1") |
Sergey Vasilinets | 511969f | 2020-01-09 12:52:23 +0000 | [diff] [blame] | 41 | |
| 42 | testImplementation(project(":internal-testutils-gradle-plugin")) |
| 43 | testImplementation gradleTestKit() |
| 44 | testImplementation(ANDROIDX_TEST_RUNNER) |
| 45 | testImplementation(JUNIT) |
| 46 | testImplementation(KOTLIN_TEST) |
Sergey Vasilinets | 4e97056 | 2019-12-12 13:39:19 +0000 | [diff] [blame] | 47 | } |
| 48 | |
| 49 | gradlePlugin { |
| 50 | plugins { |
| 51 | inspection { |
| 52 | id = "androidx.inspection" |
| 53 | implementationClass = "androidx.inspection.gradle.InspectionPlugin" |
| 54 | } |
| 55 | } |
| 56 | } |
| 57 | |
| 58 | androidx { |
| 59 | name = "Android Inspection Gradle Plugin" |
| 60 | publish = Publish.NONE |
| 61 | toolingProject = true |
Sergey Vasilinets | 4e97056 | 2019-12-12 13:39:19 +0000 | [diff] [blame] | 62 | mavenGroup = LibraryGroups.INSPECTION |
| 63 | inceptionYear = "2019" |
| 64 | description = "Android Inspection Gradle Plugin" |
| 65 | compilationTarget = CompilationTarget.HOST |
| 66 | } |