Unable to rename mipmap/icon to ic_launcher?

六眼飞鱼酱① 提交于 2021-02-11 14:25:05

问题


When i try to rename @mipmap/icon to @mipmap/ic_launcer in authenticator.xml on line 2. Any program changes back when i build my app.

    * What went wrong:
Execution failed for task ':app:processDebugResources'.
> Android resource linking failed
  C:\ES.eWarrant\eWarrant\platforms\android\app\src\main\res\xml\authenticator.xml:2: AAPT: error: resource mipmap/icon (aka io.ionic.starter:mipmap/icon) not found.

This is an error i've got when want to build ionic app.

Ionic info:

Ionic:

   ionic (Ionic CLI)  : 4.12.0 (C:\Users\ES property\AppData\Roaming\npm\node_modules\ionic)
   Ionic Framework    : ionic-angular 3.9.4
   @ionic/app-scripts : 3.2.3

Cordova:

   cordova (Cordova CLI) : 8.1.2 (cordova-lib@8.1.1)
   Cordova Platforms     : android 8.0.0, browser 5.0.4, ios 5.0.0, windows 4.4.2
   Cordova Plugins       : cordova-plugin-ionic-keyboard 2.1.3, cordova-plugin-ionic-webview 1.2.1, (and 18 other plugins)

System:

   Android SDK Tools : 26.1.1 (C:\Users\ES-Property\AppData\Local\Android\sdk)
   NodeJS            : v8.12.0 (C:\Program Files\nodejs\node.exe)
   npm               : 3.10.10
   OS                : Windows 10

回答1:


What I did was copy one of the folders mipmap-whathever on /platforms/android/app/app/src/main/res changin the name to mipmap an the ic_launcher.png to icon.png



来源:https://stackoverflow.com/questions/55703857/unable-to-rename-mipmap-icon-to-ic-launcher

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!