4

I am using Android SDK 16.1 with Eclipse on Windows.

I've set ANDROID_LINT_COMPLETE_REGIONS as a Windows environment variable per the documentation

I've rebooted my computer.

I've verified the System.getenv("ANDROID_LINT_COMPLETE_REGIONS") uses Windows System Variables.

I've verified that translation errors are turned on.

However, what I'm wanting/expecting to error is not. I have an English string in "/res/values/strings.xml" that is not in "/res/values-xx/strings.xml". I expect lint to error because I've set ANDROID_LINT_COMPLETE_REGIONS. Looking at the source in the SDK, it seems like it should work.

Anyone got something else I should try?

Update: I have tried this on a Mac and while I have persisted ANDROID_LINT_COMPLETE_REGIONS="1", I can't get an error to occur in Eclipse.

Bananeweizen
  • 21,797
  • 8
  • 68
  • 88
Justin
  • 874
  • 8
  • 15

2 Answers2

1

Whatever this problem was, upgrading to Android SDK 17 fixes this issue for me. Lint can now detect when I do not translate a string.

Justin
  • 874
  • 8
  • 15
0

I set it as a user variable (Windows XP), verified that it appears in a cmd prompt with the set command, and it appears to be working in eclipse after restarting it.

hooby3dfx
  • 936
  • 1
  • 8
  • 18
  • Can you try the scenario of putting a string in the default strings.xml only? Does it warn/error if the string only exists in the default? – Justin Jan 26 '12 at 03:26
  • Yes - that is the whole point of the MissingTranslations feature. You use ANDROID_LINT_COMPLETE_REGIONS if you have a language (ex. fr) and a region where you want full set of strings for (fr-rCA). I would also strongly recommend the tool from this question: http://stackoverflow.com/questions/6985366/android-get-missing-translations-for-strings-resources – hooby3dfx Jan 26 '12 at 14:47