Skip to content

Commit

Permalink
optimize: 添加日志。
Browse files Browse the repository at this point in the history
  • Loading branch information
wangliang181230 committed Jun 13, 2024
1 parent ffbe9f2 commit 263e236
Showing 1 changed file with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -144,8 +144,11 @@ public void execute() throws MojoExecutionException {
// 删除文件
if (file.exists()) {
try {
file.delete();
getLog().info("Delete file: " + fileInfo.getPath());
if (file.delete()) {
getLog().info("Delete file: " + fileInfo.getPath());
} else {
getLog().info("No files were deleted: " + fileInfo.getPath());
}
} catch (Exception e) {
getLog().warn("Delete file failed: " + fileInfo.getPath(), e);
}
Expand Down

0 comments on commit 263e236

Please sign in to comment.