Skip to content

Comment out unused resource strings#512

Merged
davecraig merged 2 commits into
Scottish-Tech-Army:mainfrom
davecraig:main
May 27, 2025
Merged

Comment out unused resource strings#512
davecraig merged 2 commits into
Scottish-Tech-Army:mainfrom
davecraig:main

Conversation

@davecraig

Copy link
Copy Markdown
Contributor

I'm looking at pushing our resources to Weblate for translation, so remove all those strings which are not actually used. They are left in the code, just commented out which makes it easy to see where the Android app differs from the iOS app.

davecraig added 2 commits May 27, 2025 10:28
The commentOutResourceString.sh and uncommentOutResourceString.sh scripts
take a single argument which is the resource name e.g. general_alert_yes.
This is commented/uncommented out in all strings.xml files that are
contained within "values" sub-directories.

The unusedResources.sh parses a file named unused_resources.txt and comments
out all of the files listed in that file - one filename per line. This was
used to comment out all of the resources returned by the Android Studio
"Unused resources" code analysis.
In preparation for pushing strings to Weblate for translation, comment out
all of the strings resources that we don't currently use. This also helps
see in which areas the Android app differs from the iOS app in terms of
string usage.
@davecraig davecraig changed the title Remove unused resource strings Comment out unused resource strings May 27, 2025
@davecraig davecraig merged commit d55a5d3 into Scottish-Tech-Army:main May 27, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant