import Ġcom . nov oda . gradle . release . Publish Extension Ċ import Ġorg . jetbrains . dok ka . gradle . D ok ka Task Ċ import Ġorg . jetbrains . kotlin . gradle . tasks . Kotlin Compile Ċ import Ġjava . net . URL Ċ Ċ plugins Ġ{ ĊĠĠĠ Ġid (" java - library ") ĊĠĠĠ Ġid (" kotlin ") ĊĠĠĠ Ġid (" org . jetbrains . dok ka ") ĊĠĠĠ Ġid (" org . ow asp . dependency check ") ĊĠĠĠ Ġid (" jac oco ") ĊĠĠĠ Ġid (" com . github . kt 3 k . coveralls ") ĊĠĠĠ Ġid (" com . android . lint ") Ċ } Ċ Ċ apply ( plugin Ġ= Ġ" com . nov oda . bin tray - release ") Ċ Ċ java Ġ{ ĊĠĠĠ Ġsource Compatibility Ġ= ĠJava Version . VERSION _ 1 _ 8 ĊĠĠĠ Ġtarget Compatibility Ġ= ĠJava Version . VERSION _ 1 _ 8 Ċ } Ċ Ċ dependencies Ġ{ ĊĠĠĠ Ġimplementation ( kotlin (" stdlib - jdk 7 ")) ĊĊĠĠĠ Ġ// ĠIssue Ġwith Ġjet t ifier Ġand Ġv 1 . 6 5 ĊĠĠĠ Ġ@ Suppress (" Gradle Dependency ") ĊĠĠĠ Ġimplementation (" org . bouncycastle : b cp k ix - jdk 1 5 on : 1 . 6 4 ") ĊĠĠĠ Ġ@ Suppress (" Gradle Dependency ") ĊĠĠĠ Ġimplementation (" org . bouncycastle : bc prov - jdk 1 5 on : 1 . 6 4 ") ĊĠĠĠ Ġ@ Suppress (" Gradle Dependency ") ĊĠĠĠ Ġimplementation (" org . bouncycastle : b ct ls - jdk 1 5 on : 1 . 6 4 ") ĊĊĠĠĠ Ġimplementation (" org . jetbrains . kotlin x : kotlin x - coroutines - core : 1 . 3 . 7 ") ĊĊĠĠĠ Ġimplementation (" com . squareup . ret rofit 2 : ret rofit : 2 . 9 . 0 ") ĊĠĠĠ Ġimplementation (" com . squareup . ret rofit 2 : converter - gson : 2 . 9 . 0 ") ĊĠĠĠ Ġtest Implementation (" com . squareup . ret rofit 2 : ret rofit - mock : 2 . 9 . 0 ") ĊĊĠĠĠ Ġtest Implementation (" junit : junit : 4 . 1 3 ") ĊĠĠĠ Ġtest Implementation (" org . mockito : mockito - core : 3 . 3 . 3 ") ĊĠĠĠ Ġtest Implementation (" com . n ha ar man . mock it ok otlin 2 : mockito - kotlin : 2 . 2 . 0 ") ĊĊĠĠĠ Ġtest Implementation (" nl . jq no . equals verifier : equals verifier : 3 . 3 ") Ċ } Ċ Ċ tasks . with Type ( Kotlin Compile :: class . java ). all Ġ{ ĊĠĠĠ Ġkotlin Options Ġ{ ĊĠĠĠĠĠĠĠ Ġall Warnings As Errors Ġ= Ġtrue ĊĠĠĠĠĠĠĠ Ġfree Compiler Args Ġ+= Ġ"- X use - experimental = kotlin . Experimental " ĊĠĠĠ Ġ} Ċ } Ċ Ċ tasks . getting ( D ok ka Task :: class ) Ġ{ ĊĠĠĠ Ġoutput Format Ġ= Ġ" html " ĊĠĠĠ Ġoutput Directory Ġ= Ġ"${ project . build Dir }/ javadoc " ĊĊĠĠĠ Ġconfiguration Ġ{ ĊĠĠĠĠĠĠĠ Ġexternal Documentation Link Ġ{ ĊĠĠĠĠĠĠĠĠĠĠĠ Ġurl Ġ= ĠURL (" https :// square . github . io / okhttp / 3 . x / okhttp /") ĊĠĠĠĠĠĠĠ Ġ} ĊĠĠĠ Ġ} Ċ } Ċ Ċ dependency Check Ġ{ ĊĠĠĠ Ġfail Build On CV SS Ġ= Ġ 0 f ĊĊĠĠĠ Ġsup pression File Ġ= Ġfile (" cve - suppress ions . xml "). toString () ĊĊĠĠĠ Ġanaly zers . assembly Enabled Ġ= Ġfalse ĊĊĠĠĠ Ġskip Configurations Ġ= ĠlistOf (" lint Class Path ", Ġ" jac oco Agent ", Ġ" jac oco Ant ", Ġ" kotlin Compiler Classpath ", Ġ" kotlin Compiler Plugin Classpath ") Ċ } Ċ Ċ tasks . with Type < J aco co Report > Ġ{ ĊĠĠĠ Ġreports Ġ{ ĊĠĠĠĠĠĠĠ Ġxml . isEnabled Ġ= Ġtrue ĊĠĠĠĠĠĠĠ Ġhtml . isEnabled Ġ= Ġtrue ĊĠĠĠ Ġ} Ċ } Ċ Ċ coveralls Ġ{ ĊĠĠĠ Ġsource Dirs Ġ= Ġsource Sets . main . get (). all Source . src Dirs . map Ġ{ Ġit . path Ġ} ĊĠĠĠ Ġj aco co Report Path Ġ= Ġ"$ build Dir / reports / jac oco / test / jac oco Test Report . xml " Ċ } Ċ Ċ lint Options Ġ{ ĊĠĠĠ Ġis Abort OnError Ġ= Ġtrue ĊĠĠĠ Ġis Warnings As Errors Ġ= Ġtrue Ċ } Ċ Ċ tasks . get ByName (" test "). final ized By ( tasks . get ByName (" jac oco Test Report ")) Ċ tasks . get ByName (" jac oco Test Report "). final ized By ( tasks . get ByName (" coveralls ")) Ċ tasks . get ByName (" coveralls "). only If Ġ{ ĠSystem . getenv (" CI ") ?. isNotEmpty () Ġ== Ġtrue Ġ} Ċ Ċ tasks . get ByName (" check "). depends On ( tasks . dependency Check Analyze ) Ċ tasks . get ByName (" check "). depends On ( root Project . tasks . get ByName (" de te kt ")) Ċ tasks . get ByName (" check "). depends On ( root Project . tasks . get ByName (" markdown lint ")) Ċ Ċ configure < Publish Extension > Ġ{ ĊĠĠĠ Ġbin tray User Ġ= ĠSystem . getenv (" BIN TR AY _ USER ") Ġ?: ĠSystem . getProperty (" BIN TR AY _ USER ") Ġ?: Ġ" unknown " ĊĠĠĠ Ġbin tray Key Ġ= ĠSystem . getenv (" BIN TR AY _ KEY ") Ġ?: ĠSystem . getProperty (" BIN TR AY _ KEY ") Ġ?: Ġ" unknown " ĊĊĠĠĠ Ġuser Org Ġ= Ġ" babylon partners " ĊĠĠĠ ĠgroupId Ġ= Ġ" com . babylon . certificate tr ansparency " ĊĠĠĠ Ġartifact Id Ġ= Ġ" certificate tr ansparency " ĊĠĠĠ Ġpublish Version Ġ= ĠSystem . getenv (" CIR CLE _ TAG ") Ġ?: ĠSystem . getProperty (" CIR CLE _ TAG ") Ġ?: Ġ" unknown " ĊĠĠĠ Ġdesc Ġ= Ġ" Certificate Ġtransparency Ġfor ĠAndroid Ġand ĠJava " ĊĠĠĠ Ġwebsite Ġ= Ġ" https :// github . com / babylon health / certificate - tr ansparency - android " ĊĊĠĠĠ Ġdry Run Ġ= Ġfalse Ċ } Ċ Ċ // ĠFix Ġfor Ġhttps :// github . com / nov oda / bin tray - release / issues / 2 6 2 Ċ tasks . when Task Added Ġ{ ĊĠĠĠ Ġif Ġ( name Ġ== Ġ" generate Sources Jar For Maven Publication ") Ġ{ ĊĠĠĠĠĠĠĠ Ġthis Ġas ĠJar ĊĠĠĠĠĠĠĠ Ġfrom ( source Sets . main . get (). all Source ) ĊĠĠĠ Ġ} Ċ } Ċ