How can I find all fake or useless string values in string.xml file?

Viewed 1370

I have a big and messy string.xml file with 3000 records, which most of the values are useless and never used inside code. I want to find and omit those useless records automatically. Is there a way to find useless records inside string.xml file?

5 Answers

I found the that using the lint check and the translations editor works like a charm.

Go Analyse -> Run inspection by name -> Unused resources.

Here i add a file mask to only show me the strings

with a file mask

After the check has ran go to the Translations Editor, find the key(s) right click and safe delete.

This checks of the resource can safely be deleted and deletes the key in all your locales.

Related