| apply plugin: 'com.android.library' | 
|   | 
| android { | 
|   | 
|     compileSdkVersion 26 | 
|   | 
|     defaultConfig { | 
|         //applicationId "com.secondworld.univeralsdk" | 
|         minSdkVersion 18 | 
|         targetSdkVersion 26 | 
|         versionCode 1 | 
|         versionName "1.1.0" | 
|     } | 
|   | 
|     buildTypes { | 
|         release { | 
|             //混淆 | 
|             minifyEnabled true | 
|             //对齐 | 
|             zipAlignEnabled true | 
|             proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' | 
|   | 
|         } | 
|     } | 
|   | 
|     flavorDimensions "default" | 
|     productFlavors { | 
|         // TAPTAP | 
|         game_904100357 { | 
|             dimension "default" | 
|             manifestPlaceholders.put("appId", "com.ziyouyouxi08.djxxz") | 
|             manifestPlaceholders.put("FreeSDK_AppID", "904100357") | 
|             manifestPlaceholders.put("FreeSDK_ChanelID", "1000") | 
|             manifestPlaceholders.put("FreeSDK_PlatformID", "1000") | 
|             manifestPlaceholders.put("JpushAppKey", "bc1907c74128fdbd85018a83") | 
|         } | 
|         // 少年修仙传 - 新 | 
|         game_822055139 { | 
|             dimension "default" | 
|             manifestPlaceholders.put("appId", "com.ziyouyouxi01.snxxz") | 
|             manifestPlaceholders.put("FreeSDK_AppID", "822055139") | 
|             manifestPlaceholders.put("FreeSDK_ChanelID", "1000") | 
|             manifestPlaceholders.put("FreeSDK_PlatformID", "1000") | 
|             manifestPlaceholders.put("TrackAppID", "a0304df6f4dfdd5bd7cbf6369f7f1c11") | 
|             manifestPlaceholders.put("TrackChannelID", "_default_") | 
|             manifestPlaceholders.put("JpushAppKey", "1c060648058afe0b5faf72ca") | 
|             manifestPlaceholders.put("TT_AppName", "少年修仙传") | 
|             manifestPlaceholders.put("TT_AppID", "151709") | 
|             manifestPlaceholders.put("TT_Chanel", "_default_") | 
|             dependencies { | 
|                 implementation(name: 'applog-release', ext: 'aar') | 
|             } | 
|         } | 
|         // 少年修仙传 | 
|         game_226114725 { | 
|             dimension "default" | 
|             manifestPlaceholders.put("appId", "com.shandangceshi.snxxz") | 
|             manifestPlaceholders.put("FreeSDK_AppID", "226114725") | 
|             manifestPlaceholders.put("FreeSDK_ChanelID", "1000") | 
|             manifestPlaceholders.put("FreeSDK_PlatformID", "1000") | 
|             manifestPlaceholders.put("TrackAppID", "5ae23b6b905f98d9b8bd542debf35678") | 
|             manifestPlaceholders.put("TrackChannelID", "_default_") | 
|             manifestPlaceholders.put("JpushAppKey", "22186239fee975f883198cf4") | 
|         } | 
|         // 灵仙记 | 
|         game_813015059 { | 
|             dimension "default" | 
|             manifestPlaceholders.put("appId", "com.ziyouyouxi07.snxxz") | 
|             manifestPlaceholders.put("FreeSDK_AppID", "813015059") | 
|             manifestPlaceholders.put("FreeSDK_ChanelID", "1000") | 
|             manifestPlaceholders.put("FreeSDK_PlatformID", "1000") | 
|             manifestPlaceholders.put("TrackAppID", "0c5ad863fb8935d18b3ecefe05389701") | 
|             manifestPlaceholders.put("TrackChannelID", "_default_") | 
|             manifestPlaceholders.put("JpushAppKey", "63f9523bf41727aaccfd258f") | 
|         } | 
|         // 上古搜宝录 | 
|         game_815035853 { | 
|             dimension "default" | 
|             manifestPlaceholders.put("appId", "com.ziyouyouxi05.snxxz") | 
|             manifestPlaceholders.put("FreeSDK_AppID", "815035853") | 
|             manifestPlaceholders.put("FreeSDK_ChanelID", "1000") | 
|             manifestPlaceholders.put("FreeSDK_PlatformID", "1000") | 
|             manifestPlaceholders.put("TrackAppID", "9e16495be922a78c4dbef24d8adc9c36") | 
|             manifestPlaceholders.put("TrackChannelID", "_default_") | 
|             manifestPlaceholders.put("JpushAppKey", "44329480f1b4ac22d737c559") | 
|         } | 
|         // 测试专用(test) | 
|         secondworld { | 
|             dimension "default" | 
|             manifestPlaceholders.put("appId", "com.secondworld.snxxz") | 
|             manifestPlaceholders.put("FreeSDK_AppID", "226114725") | 
|             manifestPlaceholders.put("FreeSDK_ChanelID", "1000") | 
|             manifestPlaceholders.put("FreeSDK_PlatformID", "1000") | 
|             manifestPlaceholders.put("TrackAppID", "5ae23b6b905f98d9b8bd542debf35678") | 
|             manifestPlaceholders.put("TrackChannelID", "_default_") | 
|             manifestPlaceholders.put("JpushAppKey", "22186239fee975f883198cf4") | 
|         } | 
|     } | 
| } | 
|   | 
| repositories { | 
|     flatDir { | 
|         dirs 'libs' | 
|     } | 
| } | 
|   | 
| dependencies { | 
|     implementation files('libs/android-support-v4.jar') | 
|     implementation files('libs/gson.jar') | 
|     implementation files('libs/okhttp.jar') | 
|     implementation files('libs/okio.jar') | 
|     implementation files('libs/tracking1.3.0.jar') | 
|     implementation files('libs/jcore-android-1.2.1.jar') | 
|     implementation files('libs/jpush-android-3.1.3.jar') | 
|     compileOnly files('libs/unity-classes.jar') | 
|     implementation files('libs/bugly.jar') | 
|     implementation files('libs/buglyagent.jar') | 
|     implementation(name: 'freesdk-release', ext: 'aar') | 
| } | 
|   | 
| task autoCopy_815035853_Manifest(type: Copy) { | 
|     dependsOn 'assembleGame_815035853Release' | 
|     from zipTree("build/outputs/aar/app-game_815035853-release.aar") | 
|     include "AndroidManifest.xml" | 
|     into "C:\\Unity3D_SDK\\ChannelDiff\\Android\\815035853\\" | 
| } | 
|   | 
| task autoCopy_815035853(type: Copy) { | 
|     dependsOn autoCopy_815035853_Manifest | 
|     from "build/outputs/aar/" | 
|     include "app-game_815035853-release.aar" | 
|     into "C:\\Unity3D_SDK\\ChannelDiff\\Android\\815035853\\libs\\" | 
| } | 
|   | 
| task autoCopy_226114725_Manifest(type: Copy) { | 
|     dependsOn 'assembleGame_226114725Release' | 
|     from zipTree("build/outputs/aar/app-game_226114725-release.aar") | 
|     include "AndroidManifest.xml" | 
|     into "C:\\Unity3D_SDK\\ChannelDiff\\Android\\226114725\\" | 
| } | 
|   | 
| task autoCopy_226114725(type: Copy) { | 
|     dependsOn autoCopy_226114725_Manifest | 
|     from "build/outputs/aar/" | 
|     include "app-game_226114725-release.aar" | 
|     into "C:\\Unity3D_SDK\\ChannelDiff\\Android\\226114725\\libs\\" | 
| } | 
|   | 
| task autoCopy_822055139_Manifest(type: Copy) { | 
|     dependsOn 'assembleGame_822055139Release' | 
|     from zipTree("build/outputs/aar/app-game_822055139-release.aar") | 
|     include "AndroidManifest.xml" | 
|     into "C:\\Unity3D_SDK\\ChannelDiff\\Android\\822055139\\" | 
| } | 
|   | 
| task autoCopy_822055139(type: Copy, dependsOn: autoCopy_822055139_Manifest) { | 
|     from "build/outputs/aar/" | 
|     include "app-game_822055139-release.aar" | 
|     into "C:\\Unity3D_SDK\\ChannelDiff\\Android\\822055139\\libs\\" | 
| } | 
|   | 
| task autoCopy_904100357_Manifest(type: Copy) { | 
|     dependsOn 'assembleGame_904100357Release' | 
|     from zipTree("build/outputs/aar/app-game_904100357-release.aar") | 
|     include "AndroidManifest.xml" | 
|     into "C:\\Unity3D_SDK\\ChannelDiff\\Android\\904100357\\" | 
| } | 
|   | 
| task autoCopy_904100357(type: Copy, dependsOn: autoCopy_904100357_Manifest) { | 
|     from "build/outputs/aar/" | 
|     include "app-game_904100357-release.aar" | 
|     into "C:\\Unity3D_SDK\\ChannelDiff\\Android\\904100357\\libs\\" | 
| } | 
|   | 
| task autoCopy_813015059_Manifest(type: Copy) { | 
|     dependsOn 'assembleGame_813015059Release' | 
|     from zipTree("build/outputs/aar/app-game_813015059-release.aar") | 
|     include "AndroidManifest.xml" | 
|     into "C:\\Unity3D_SDK\\ChannelDiff\\Android\\813015059\\" | 
| } | 
|   | 
| task autoCopy_813015059(type: Copy, dependsOn: autoCopy_813015059_Manifest) { | 
|     from "build/outputs/aar/" | 
|     include "app-game_813015059-release.aar" | 
|     into "C:\\Unity3D_SDK\\ChannelDiff\\Android\\813015059\\libs\\" | 
| } | 
|   | 
| task autoCopySecondWorldAndroidManifest(type: Copy) { | 
|     dependsOn 'assembleSecondworldRelease' | 
|     from zipTree("build/outputs/aar/app-secondworld-release.aar") | 
|     include "AndroidManifest.xml" | 
|     into "C:\\Unity3D_SDK\\ChannelDiff\\Android\\test\\" | 
| } | 
|   | 
| task autoCopySecondWorldAAR(type: Copy) { | 
|     dependsOn autoCopySecondWorldAndroidManifest | 
|     from 'build/outputs/aar/' | 
|     include "app-secondworld-release.aar" | 
|     into 'C:\\Unity3D_SDK\\ChannelDiff\\Android\\test\\libs\\' | 
| } |