I use Log functions to debug my Android app. I’m close to releasing my app and I’d like to reduce debug level. However I don’t know how to disable some of these function. Say I just want to disable Log.v() logs.
Android doc says here that one should remove Log functions calls in code or remove/set to false the android::debbugable option. The first option does not fit my needs, since I’d like to Log calls in my source code (for future updates). The second option disables all logs, which is not convenient for pre-release testing.
Do you know how to disable only verbose (Log.v) logs ?
Many thanks!
You could create your own wrapper for the
Log-class, maybe something like this:Then you can use
MyLog.setLevel(1);to disable any verbose logging (or a higher level to disable those logs as well).