首页 > 解决方案 > android studio:在调试或构建时创建我的两个应用程序

问题描述

我的应用突然开始在我的手机上用真实的应用构建另一个应用..

并且两人正在打开同一个应用程序

当我删除一个时,另一个也被删除

那么问题是什么

为什么这样做

即使在我发布了它之后..

它生成两个版本..两个应用程序

这是我的 gradle 文件

    apply plugin: 'com.android.application'

android {
    compileSdkVersion 28
    defaultConfig {
        vectorDrawables.useSupportLibrary = true

        applicationId "app.example.example"
        minSdkVersion 17
        targetSdkVersion 28
        versionCode 1
        versionName "1.0"
        multiDexEnabled true
        testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
    }
    buildTypes {
        release {
            minifyEnabled true
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }
    }
}

dependencies {
    implementation fileTree(dir: 'libs', include: ['*.jar'])
    implementation 'com.android.support:appcompat-v7:28.0.0'
    implementation 'com.android.support:design:28.0.0'
    implementation 'com.android.support:support-v4:28.0.0'
    implementation 'com.android.support:support-media-compat:28.0.0'
//    implementation 'com.android.support:design:28.0.0'
    implementation 'com.android.support:customtabs:28.0.0'
    implementation 'com.android.support:cardview-v7:28.0.0'
    implementation 'com.android.support:exifinterface:28.0.0'
    implementation 'com.android.support.constraint:constraint-layout:1.1.3'
    implementation "androidx.constraintlayout:constraintlayout:1.1.3"
    testImplementation 'junit:junit:4.12'
    androidTestImplementation 'com.android.support.test:runner:1.0.2'
    androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
    implementation 'com.android.support:multidex:1.0.3'

    //  Butter Knife
    implementation 'com.jakewharton:butterknife:8.8.1'
    annotationProcessor 'com.jakewharton:butterknife-compiler:8.8.1'

//  Circle ImageView
    implementation 'de.hdodenhof:circleimageview:2.2.0'

//  ImageCropping
    implementation 'com.theartofdev.edmodo:android-image-cropper:2.7.+'
//    https://github.com/ArthurHub/Android-Image-Cropper

//  EasyPermissions
    implementation 'pub.devrel:easypermissions:1.2.0'
//    https://github.com/googlesamples/easypermissions

//  FireBase

    implementation 'com.firebaseui:firebase-ui-firestore:4.0.0'
    implementation 'com.firebaseui:firebase-ui-auth:4.0.0'
    implementation 'com.firebaseui:firebase-ui-storage:4.0.0'
    implementation 'com.google.firebase:firebase-messaging:17.0.0'
    implementation 'com.google.firebase:firebase-core:16.0.0'
    implementation 'com.facebook.android:facebook-login:[4,5)'
    implementation 'id.zelory:compressor:2.1.0'

//  fonts to all app
    implementation 'uk.co.chrisjenx:calligraphy:2.2.0'

//  Glide
    implementation 'com.github.bumptech.glide:glide:4.8.0'
    annotationProcessor 'com.github.bumptech.glide:compiler:4.8.0'

//    https://github.com/bumptech/glide

    implementation('com.mikepenz:materialdrawer:5.9.5@aar') {
        transitive = true
        exclude group: 'com.android.support'
    }


    implementation 'com.github.ganfra:material-spinner:2.0.0'

    implementation 'com.github.aakira:expandable-layout:1.6.0@aar'

    implementation "commons-io:commons-io:+"


}
apply plugin: 'com.google.gms.google-services'

标签: androidandroid-studio

解决方案


仔细检查您的 AndroidManifest.xml 文件中的两个主要活动。通常,一个应用程序将只有一个带有意图过滤器的活动,该意图过滤器具有主要操作和启动器类别。


推荐阅读