Skip to content

Commit

Permalink
feat: 当开启对齐时,自动删除对齐的中间产物xxx_aligned.apk
Browse files Browse the repository at this point in the history
  • Loading branch information
jixiaoyong committed Jan 25, 2024
1 parent cebf383 commit 240b187
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/main/kotlin/io/github/jixiaoyong/utils/ApkSigner.kt
Original file line number Diff line number Diff line change
Expand Up @@ -195,6 +195,14 @@ object ApkSigner {
} catch (e: Exception) {
Logger.error("签名失败", e)
return CommandResult.Error("${e.message}", e)
}finally {
if (zipAlign) {
try {
File(alignedApkFilePath).delete()
}catch (e: Exception) {
Logger.error("删除文件失败", e)
}
}
}
}
return CommandResult.Success(outPutFilePath)
Expand Down

0 comments on commit 240b187

Please sign in to comment.