Wish Can we have '#if Release (obfuscated)' ?

AnandGupta

Expert
Licensed User
Longtime User
We already have
B4X:
#if Release
    'copy the apk in zip with version number for upload
#end if
#if Debug
   '
#end if

Can we have in next B4A version ?
B4X:
#if Release (obfuscated)

I want to copy apk only when obfuscated released.
 

DonManfred

Expert
Licensed User
Longtime User
I want to copy apk only when obfuscated released.
Isn´t the obfuscatormap file (don´t know the exact filename) only generated when using obfuscated?
 

tchart

Well-Known Member
Licensed User
Longtime User
I’ve asked this for B4J as well;

 

tchart

Well-Known Member
Licensed User
Longtime User
Isn´t the obfuscatormap file (don´t know the exact filename) only generated when using obfuscated?
The point it that release isn’t necessarily the final release (it’s just a build). I too have different actions I need to perform when I do a public release (obfuscated).
 
Last edited:

toby

Well-Known Member
Licensed User
Longtime User
You can achieve what you want by simply doing the following
1. Create a Conditional symbol Release_obfuscated for the build Release (obfuscated)
2. In your code
B4X:
#if Release_obfuscated
    'custom action here'
#end if
 

tchart

Well-Known Member
Licensed User
Longtime User
You can achieve what you want by simply doing the following
1. Create a Conditional symbol Release_obfuscated for the build Release (obfuscated)
2. In your code
B4X:
#if Release_obfuscated
    'custom action here'
#end if
As mentioned in my request the problem with conditional symbols is that they are per project and require you to select the build configuration.
 

imbault

Well-Known Member
Licensed User
Longtime User
Yes, but easier if native, not very complicated for Erel to add
 

AnandGupta

Expert
Licensed User
Longtime User
You can achieve what you want by simply doing the following
1. Create a Conditional symbol Release_obfuscated for the build Release (obfuscated)
2. In your code
B4X:
#if Release_obfuscated
    'custom action here'
#end if
No it does not work. For both "Release" and "Release (obfuscated)" from drop-down, highlights below region in red and never #if Release_obfuscated
B4X:
#if Release
 
Top