This is a recipe for Transnomino app on Mac to rename and move files exported from Figma to an Android app's drawable folders.
There's one assumption here that layer names in figma are something like
Light/Layer Name and
Dark/Layer Name. Although, I imagine it'd be trivial to change it to something that's separated by a character other than
In Figma, the layer suffixes needs to be either
- HDPI, MDPI, XHDPI, XXHDPI, XXXHDPI
- -hdpi, -mdpi, -xhdpi, -xxhdpi, -xxxhdpi
If using #2, disable the 3rd step (Hyphenate suffix).