简体   繁体   中英

How to target app version in Firebase RemoteConfig for some build version and greater using contains regex in conditions?

I'm trying to make a condition to only target some specific App build and greater. For example I want to target App version 26 and above. Is that possible to do? what is the right syntax for the regex?

and I know according to Firebase documentation, it's the CFBundleVersion and not the CFBundleShortVersionString.

The only solution I came up with and it has some limitations:

^0.0.([1-9][1-9]|[1-9][0-9][0-9])$

For example: this will allow the following range 0.0.11-999

in my case my build version is 0.0.10, so I wanna target anything greater than 0.0.10. My new build version 0.0.15

Limitations: Any number that ends with 0 will return false, so to solve it don't use the following numbers as a build version 20,30,40,50,60,70,80,90

You can test your condition using this great tool: https://regex101.com

It became available now with greater than, lower than and equals according to this blog post https://firebase.blog/posts/2020/10/improved-version-targeting-in-remote

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM