如何在flutter项目中重命名应用程序包?

问题描述 投票:0回答:1

我想重命名我的应用程序包,因为我的应用程序包是com.example.example,所以我无法在Play商店上载我的应用程序。如何轻松更改?

android flutter bundle id
1个回答
0
投票

对于Android

转到,应用程序级别为build.gradle,并指定唯一的应用程序ID

    defaultConfig {
    applicationId "your-package-name"
    minSdkVersion 16
    targetSdkVersion 27
    versionCode flutterVersionCode.toInteger()
    versionName flutterVersionName
    testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
    multiDexEnabled true
}

对于IOS

转到Info.plist目录中的ios/Runner,并更改捆绑程序标识符

<key>CFBundleIdentifier</key>
<string>com.your.packagename</string>
© www.soinside.com 2019 - 2024. All rights reserved.