I'm testing the release version of the app on the actual machine, but when I run it from Android Studio (with --debug
), I get an error (probably because the application ID is the same) and the app disappears.
buildTypes{
debug {
debugable true
applicationIdSuffix ".debug"
}
If you add , the application ID is <App ID>.debug, but it is different from the application ID in google-services.json, so you still get an error.To avoid errors, you must manually change the package_name in Google-services.json.
How can I automatically run it in debug mode?
Not verified, but
to the android/app/src/debug
directory
How about placing a copy of google-services.json
that changed package_name
?
https://stackoverflow.com/questions/38609868/android-buildtypes-applicationidsuffix-error
By the way, in my case, I prepare and separate Flavor
.
https://flutter.dev/docs/deployment/flavors
© 2024 OneMinuteCode. All rights reserved.