打包APK文件名修改
Showing
1 changed file
with
8 additions
and
0 deletions
| ... | @@ -143,6 +143,14 @@ android.applicationVariants.all { variant -> | ... | @@ -143,6 +143,14 @@ android.applicationVariants.all { variant -> |
| 143 | into outputDir | 143 | into outputDir |
| 144 | } | 144 | } |
| 145 | } | 145 | } |
| 146 | |||
| 147 | variant.outputs.all { | ||
| 148 | outputFileName = "ForFun_FJ_CMCC_v${variant.versionName}_${releaseTime()}_${variant.buildType.name}.apk" | ||
| 149 | } | ||
| 150 | } | ||
| 151 | |||
| 152 | def releaseTime() { | ||
| 153 | return new Date().format("yyyyMMddHHmm", TimeZone.getTimeZone("GMT+08:00")) | ||
| 146 | } | 154 | } |
| 147 | 155 | ||
| 148 | dependencies { | 156 | dependencies { | ... | ... |
-
Please register or sign in to post a comment