Flutter Android 正式打包

打开androidStudio软件

1.修改版本号。

android->app->src->main->AndroidManifest.xml中的 android:versionCode="2" android:versionName="1.0.2"

2.打开flutter项目中的android文件夹。

3.依次点击android Studio上面的Build-> Generate Signed Bundle/APK... ->APK

4.第一次打包的话,需要创建New Key Store

  1)选择存储key的目录。(Key store path)

  2)设置签名的密码。(Password和Confirm)

  3)设置应用的别名。(Alias)

  4)设置Key的密码。(Key中的 Password和Confirm)可以和签名的密码一致

  5)在Certificate[证明书]中填写公司的相关信息。

  6)Ok之后在对应目录生成.jks文件(需保存好,升级的时候需要用到)

5.Next之后,选择Build Variants中的 release  在选择 V1(Jar Signature),点击Finith就打包完成了。

 

升级应用 重新打包

1)修改版本号。

android->app->src->main->AndroidManifest.xml中的 android:versionCode="2" android:versionName="1.0.2"

2)修改pubspec.yaml中的 version版本号,前面就是versionName+versionCode。

3)打包按第一次的设置依次执行就可以了

 

相关文章:

  • 2021-10-29
  • 2022-03-01
  • 2022-12-23
  • 2021-12-12
  • 2021-06-03
  • 2021-07-10
  • 2022-01-26
猜你喜欢
  • 2021-08-02
  • 2022-01-16
  • 2022-01-06
  • 2022-12-23
  • 2021-11-30
  • 2021-10-06
相关资源
相似解决方案