After I had again fun with missing AppleScript permissions I thought I could add a check if the InfoPlist.strings are written. But I can’t get the Shell script to work.
The reason your original command doesn’t work is that you are both quoting and escaping the path name. If you are using backslashes for spaces in the path, then you would not put it in quotes.
E.g. use one or the other, but not both:
// Escaped form - spaces must be preceeded by backslashes
/Applications/Mail\ Archiver\ X\ 6.1.3.app/Contents/Resources/de.lproj/InfoPlist.strings
or
// Quoted form - spaces are not escaped
"/Applications/Mail Archiver X 6.1.3.app/Contents/Resources/de.lproj/InfoPlist.strings"
@Mike_D : I tried that, too, and forgot to remove one of the \ which I only saw after starting hard. The problem is that CurrentBuildLocation usually already comes as shell path.
Also, I believe you can combine escaped and unescaped paths if you get the quoting right, e.g. /Path \ to \ my \ app\".app/some subfolder with spaces/" is a legit way to do it, combining the two styles.
The CurrentBuildLocationNative worked nicely. I had to fight with the echo for quite some time so it didn’t echo to Xojo with a dialog. Another High Sierra problem probably.
Here is my final solution:
command = "if [ -f """ + CurrentBuildLocationNative + "/" + CurrentBuildAppName + "/Contents/Resources/de.lproj/InfoPlist.strings"" ]; then /bin/echo 'ok'; else /bin/echo 'not okay'; fi"
theResult = DoShellCommand(command)
if inStr(theResult, "not okay") > 0 then
print "AppleScript permissions missing"
end if