混淆配置,所有的包增加classifier为xj,只对biz包混淆,混淆后classifier为obf,profile配置写好,混淆打包时勾选biz-obf+default打包,不混淆时只勾选default
This commit is contained in:
@@ -0,0 +1,35 @@
|
||||
-keepattributes *Annotation*, Signature, InnerClasses, EnclosingMethod, Exceptions
|
||||
-keep @org.springframework.stereotype.Service class *
|
||||
-keep @org.springframework.web.bind.annotation.RestController class *
|
||||
-keep @org.springframework.context.annotation.Configuration class *
|
||||
-keep @org.springframework.stereotype.Component class *
|
||||
-keepclassmembers enum * { # 保留枚举结构
|
||||
public static **[] values();
|
||||
public static ** valueOf(java.lang.String);
|
||||
}
|
||||
-keepclassmembers class * implements java.io.Serializable { *; }
|
||||
-keepclassmembers class * {
|
||||
@org.springframework.web.bind.annotation.*Mapping *;
|
||||
}
|
||||
-keepclassmembers class * {
|
||||
private static synthetic java.lang.Object $deserializeLambda$(java.lang.invoke.SerializedLambda);
|
||||
}
|
||||
-keep class lombok.** { *; }
|
||||
-keepclassmembers class * {
|
||||
@lombok.Getter *;
|
||||
@lombok.Setter *;
|
||||
}
|
||||
# MyBatis 专用保留规则
|
||||
-keep interface org.jeecg.**.mapper.** { *; }
|
||||
-keepclassmembers class org.jeecg.**.entity.** { *; }
|
||||
-dontwarn org.jeecg.**.entity.**
|
||||
|
||||
# 关闭优化和压缩(避免框架兼容性问题)
|
||||
-dontshrink # 不删除未使用代码
|
||||
-dontoptimize # 不优化字节码[5,6](@ref)
|
||||
-keepdirectories
|
||||
-dontusemixedcaseclassnames
|
||||
-adaptclassstrings
|
||||
# 混淆选项
|
||||
-useuniqueclassmembernames # 成员名称唯一化
|
||||
-ignorewarnings
|
||||
Reference in New Issue
Block a user