/* Ċ Ġ* ĠCopyright Ġ( C ) Ġ 2 0 2 1 ĠR ick ĠBus ar ow Ċ Ġ* ĠLicensed Ġunder Ġthe ĠApache ĠLicense , ĠVersion Ġ 2 . 0 Ġ( the Ġ" License "); Ċ Ġ* Ġyou Ġmay Ġnot Ġuse Ġthis Ġfile Ġexcept Ġin Ġcompliance Ġwith Ġthe ĠLicense . Ċ Ġ* ĠYou Ġmay Ġobtain Ġa Ġcopy Ġof Ġthe ĠLicense Ġat Ċ Ġ* Ċ Ġ* ĠĠĠĠĠ Ġhttp :// www . apache . org / licenses / LICENSE - 2 . 0 Ċ Ġ* Ċ Ġ* ĠUnless Ġrequired Ġby Ġapplicable Ġlaw Ġor Ġagreed Ġto Ġin Ġwriting , Ġsoftware Ċ Ġ* Ġdistributed Ġunder Ġthe ĠLicense Ġis Ġdistributed Ġon Ġan Ġ" AS ĠIS " ĠBASIS , Ċ Ġ* ĠWITHOUT ĠWARRANTIES ĠOR ĠCONDITIONS ĠOF ĠANY ĠKIND , Ġeither Ġexpress Ġor Ġimplied . Ċ Ġ* ĠSee Ġthe ĠLicense Ġfor Ġthe Ġspecific Ġlanguage Ġgoverning Ġpermissions Ġand Ċ Ġ* Ġlimitations Ġunder Ġthe ĠLicense . Ċ Ġ*/ Ċ Ċ plugins Ġ{ ĊĠ Ġandroid Application ĊĠ Ġid (" com . squareup . an vil ") ĊĠ Ġkotlin (" k apt ") ĊĠ Ġsc abb ard Ċ } Ċ Ċ android Ġ{ ĊĠ Ġ/* ĊĠ ĠThis Ġsample Ġapp Ġrequires Ġan Ġapi Ġkey . Ġ ĠYou Ġcan Ġget Ġa Ġfree Ġone Ġhere : Ġhttps :// the dog api . com / signup ĊĊĠ ĠAfter Ġgetting Ġyour Ġown Ġkey , Ġit Ġneeds Ġto Ġbe Ġset Ġas Ġa ĠGradle Ġproperty , ĊĠ Ġsuch Ġas Ġin Ġany Ġgradle . properties Ġfile . ĠNot Ġthat Ġyou 'll Ġprobably Ġever Ġuse Ġit Ġagain , ĊĠ Ġbut Ġthe Ġbest Ġplace Ġto Ġput Ġit Ġwould Ġbe Ġin Ġyour Ġglobal ĠGradle Ġhome . ĊĊĠ ĠAdd Ġthis Ġline Ġsomewhere , Ġsuch Ġas Ġ~/. gradle / gradle . properties : ĊĠĠĠ Ġt angle . dog . api . key =< your Ġown Ġkey > ĊĠ Ġ*/ ĊĠ Ġval Ġdog ApiKey Ġ= Ġproject . extra . properties [" t angle . dog . api . key "] Ġas ? ĠString Ġ?: Ġ"" ĊĊĠ Ġdefault Config Ġ{ ĊĊĠĠĠ Ġbuild Config Field (" String ", Ġ" DOG _ API _ KEY ", Ġ"\" $ dog ApiKey \" ") ĊĊĠĠĠ Ġtest Instrumentation Runner Ġ= Ġ" t angle . sample . app . support . T angle TestRunner " ĊĠ Ġ} ĊĊĠ Ġbuild Features Ġ{ ĊĠĠĠ Ġview Binding Ġ= Ġtrue ĊĠĠĠ Ġcompose Ġ= Ġtrue ĊĠ Ġ} ĊĠ Ġcompose Options Ġ{ ĊĠĠĠ Ġkotlin Compiler Extension Version Ġ= Ġlibs . versions . android x . compose . get () ĊĠ Ġ} ĊĠ Ġpackaging Options Ġ{ ĊĠĠĠ Ġresources . exclude s . add (" META - INF /*. kotlin _ module ") ĊĠĠĠ Ġresources . exclude s . add (" META - INF / AL 2 . 0 ") ĊĠĠĠ Ġresources . exclude s . add (" META - INF / DEPEND ENCI ES ") ĊĠĠĠ Ġresources . exclude s . add (" META - INF / DEPEND ENCI ES . txt ") ĊĠĠĠ Ġresources . exclude s . add (" META - INF / dependencies . txt ") ĊĠĠĠ Ġresources . exclude s . add (" META - INF / L GPL 2 . 1 ") ĊĠĠĠ Ġresources . exclude s . add (" META - INF / LICENSE ") ĊĠĠĠ Ġresources . exclude s . add (" META - INF / LICENSE - notice . md ") ĊĠĠĠ Ġresources . exclude s . add (" META - INF / LICENSE . md ") ĊĠĠĠ Ġresources . exclude s . add (" META - INF / LICENSE . txt ") ĊĠĠĠ Ġresources . exclude s . add (" META - INF / license . txt ") ĊĠĠĠ Ġresources . exclude s . add (" META - INF / licenses / ASM ") ĊĠĠĠ Ġresources . exclude s . add (" META - INF / NOTICE ") ĊĠĠĠ Ġresources . exclude s . add (" META - INF / NOTICE . txt ") ĊĠĠĠ Ġresources . exclude s . add (" META - INF / notice . txt ") ĊĠĠĠ Ġresources . exclude s . add (" META - INF / versions /**/*. class ") ĊĠĠĠ Ġresources . exclude s . add (" win 3 2 - x 8 6 - 6 4 / attach _ hot spot _ windows . dll ") ĊĠĠĠ Ġresources . exclude s . add (" win 3 2 - x 8 6 / attach _ hot spot _ windows . dll ") ĊĠ Ġ} Ċ } Ċ Ċ dependencies Ġ{ ĊĊĠ Ġk apt ( libs . google . d agger . compiler ) ĊĊĠ Ġk apt Android Test ( libs . google . d agger . compiler ) ĊĊĠ Ġandroid Test Implementation ( libs . android x . arch . test . core ) ĊĠ Ġandroid Test Implementation ( libs . android x . compose . test . junit ) ĊĠ Ġandroid Test Implementation ( libs . android x . test . core ) ĊĠ Ġandroid Test Implementation ( libs . android x . test . espress o . core ) ĊĠ Ġandroid Test Implementation ( libs . android x . test . espress o . id ling Resource ) ĊĠ Ġandroid Test Implementation ( libs . android x . test . j Unit ) ĊĠ Ġandroid Test Implementation ( libs . android x . test . rules ) ĊĠ Ġandroid Test Implementation ( libs . android x . test . runner ) ĊĠ Ġandroid Test Implementation ( libs . rick Bus ar ow . dispatch . espress o ) ĊĊĠ Ġanv il ( projects . t angle Compiler ) ĊĠ Ġanv il ( projects . t angle Fragment Compiler ) ĊĠ Ġanv il ( projects . t angle View model Compiler ) ĊĠ Ġanv il ( projects . t angle Work Compiler ) ĊĊĠ Ġanv il Android Test ( projects . t angle Compiler ) ĊĠ Ġanv il Android Test ( projects . t angle Fragment Compiler ) ĊĠ Ġanv il Android Test ( projects . t angle View model Compiler ) ĊĠ Ġanv il Android Test ( projects . t angle Work Compiler ) ĊĊĠ Ġapi ( projects . sample . core ) ĊĠ Ġapi ( projects . sample . data ) ĊĠ Ġapi ( projects . t angle Api ) ĊĊĠ Ġdebug Implementation ( libs . android x . compose . test . manifest ) ĊĊĠ Ġimplementation ( libs . android x . activity . k tx ) ĊĠ Ġimplementation ( libs . android x . appcompat ) ĊĠ Ġimplementation ( libs . android x . compose . material . core ) ĊĠ Ġimplementation ( libs . android x . compose . runtime ) ĊĠ Ġimplementation ( libs . android x . compose . ui . core ) ĊĠ Ġimplementation ( libs . android x . compose . ui . tool ing ) ĊĠ Ġimplementation ( libs . android x . constraint Layout ) ĊĠ Ġimplementation ( libs . android x . fragment . k tx ) ĊĠ Ġimplementation ( libs . android x . lifecycle . viewModel . compose ) ĊĠ Ġimplementation ( libs . android x . lifecycle . viewModel . k tx ) ĊĠ Ġimplementation ( libs . android x . navigation . fragment . k tx ) ĊĠ Ġimplementation ( libs . android x . navigation . ui . k tx ) ĊĠ Ġimplementation ( libs . android x . paging . compose ) ĊĠ Ġimplementation ( libs . android x . startup . runtime ) ĊĠ Ġimplementation ( libs . android x . work . k tx ) ĊĠ Ġimplementation ( libs . co il . compose ) ĊĠ Ġimplementation ( libs . google . d agger . api ) ĊĠ Ġimplementation ( libs . google . material . android ) ĊĊĠ Ġimplementation ( projects . sample . ui ) ĊĠ Ġimplementation ( projects . t angle Fragment Api ) ĊĠ Ġimplementation ( projects . t angle View model Activity ) ĊĠ Ġimplementation ( projects . t angle View model Api ) ĊĠ Ġimplementation ( projects . t angle View model Compose ) ĊĠ Ġimplementation ( projects . t angle View model Fragment ) ĊĠ Ġimplementation ( projects . t angle Work Api ) ĊĊĠ Ġtest Implementation ( projects . t angle TestUtils ) Ċ } Ċ Ċ tasks . with Type < org . jetbrains . kotlin . gradle . tasks . Kotlin Compile >() ĊĠ Ġ. configure Each Ġ{ ĊĊĠĠĠ Ġkotlin Options Ġ{ ĊĊĠĠĠĠĠ Ġfree Compiler Args Ġ= Ġfree Compiler Args Ġ+ ĠlistOf ( ĊĠĠĠĠĠĠĠ Ġ"- X opt - in = kotlin x . coroutines . Experimental Cor outines Api " ĊĠĠĠĠĠ Ġ) ĊĠĠĠ Ġ} ĊĠ Ġ} Ċ Ċ // Ġadapted Ġfrom ĠT ivi Ċ // Ġhttps :// github . com / chr is ban es / t ivi / blob / main / app / build . gradle # L 2 1 3 - L 2 2 3 Ċ android Components . on Variants Ġ{ Ġvariant Ġ-> ĊĠ Ġval Ġcaps Ġ= Ġvariant . name . capitalize () ĊĠ Ġtasks . register (" open $ caps ", ĠExec :: class . java ) Ġ{ ĊĠĠĠ Ġdepends On (" install $ caps ") ĊĊĠĠĠ Ġval Ġargs Ġ= ĊĠĠĠĠĠ Ġ" adb Ġshell Ġmonkey Ġ- p Ġ${ variant . application Id . get ()} Ġ- c Ġandroid . intent . category . LA UNCH ER Ġ 1 " ĊĠĠĠĠĠĠĠ Ġ. split (" Ġ") ĊĊĠĠĠ Ġcommand Line ( args ) ĊĠ Ġ} Ċ } Ċ