AndroidStudio 2.1 + Gradle 2.13 - altering the new rules that restricts drawable artifacts to only .png and .xml files


(Andrew Roberts) #1

What’s the necessary tweak to the gradle 2.13 rule set, to permit something other than a .png or .xml file as a drawable eg.

Error:Execution failed for task ':app:mergeDebugResources'.
> /Users/... /app/src/main/res/drawable/background.svg: Error: The file name must end with .xml or .png

FYI: renaming the .svg to a .xml doesn’t work with the rule-set, as .svg files don’t have a DOCTYPE, which there’s also a gradle requirement for, and so on.