javiersantos / AppUpdater

A library that checks for your apps' updates on Google Play, GitHub, Amazon, F-Droid or your own server. API 9+ required.
Apache License 2.0
1.98k stars 412 forks source link

Provide a way to supply custom callback to solve debug package names in getAppPackageName #142

Open sillysachin opened 6 years ago

sillysachin commented 6 years ago
    UtilsLibrary() {
    }

    static String getAppName(Context context) {
        return context.getString(context.getApplicationInfo().labelRes);
    }

    static String getAppPackageName(Context context) {
        String appId = context.getPackageName().replace(".debug", "");
        return appId;
    }

In my case in debug mode the package name is app + ".debug" and hence cannot test the same in debug mode . It would be immense help if this is made configurable. Any other suggestion i welcome.