Build and install the application
1- After making all your changes and modifications, save all your projects, open the console, navigate to your project file and execute the following command to build your application
flutter build apk --releaseIf you are publishing the app in the Play Store, it is recommended to use app bundles or split APK to reduce the size of the app. To create the application package, run:
flutter build appbundle --target-platform android-arm,android-arm64,android-x64Learn more: https://developer.android.com/guide/app-bundle To split APKs per ABI, run:
flutter build apk --target-platform android-arm,android-arm64,android-x64 --split-per-abiLearn more: https://developer.android.com/studio/build/configure-apk-splits#configure-abi-split
You should get the apk file inbuild/output/apk file, to install your application on your connected device, follow the command below:
flutter install2- If you want to upload your app to Google Play, you must sign it before uploading, generate the sign it key by running the following command:
keytool -genkey -v -keystore android/app/key.jks -keyalg RSA -keysize 2048 -validity 10000 -alias key3- Open /android/key.propertiesAnd modify the following attributes to rebuild your application:
storePassword=<Your Key Password>
keyPassword=<Your Key Password>
keyAlias=key
storeFile=key.jksLast updated