Convert android adaptive icon to png in command line

597 views Asked by At

Suppose we have an adaptive icon like this:

<adaptive-icon
  xmlns:android="http://schemas.android.com/apk/res/android">
    <background android:drawable="@mipmap/ic_launcher_background" />
    <foreground android:drawable="@mipmap/ic_launcher_foreground" />
</adaptive-icon>

How can we convert it to png format in a bash script?

My initial solution is: write a java program (like this) and use android SDK to convert to png and run the java in the bash. But is there a simpler solution? (as this requires android sdk to run)

0

There are 0 answers