TL DR:
OK, the easiest way would be a shell / python script, because it will work for each build server. I assume that you have a different scheme for each goal (otherwise it would be pointless). So what you can do is:
Let's say your goal is called:
1) Creating separate files contains all the lines that should be different (I put it in the Localizable directory.
Your Localizable.strings file might look like this:
"someGeneralString" = "General string 1"; "AppName" = "This is a string that you probably need to change"; "someOtherGeneralString" = "General string 2";
And any of your targetX.strings files might look like this:
"AppName" = "target[x]"
And this is how it should look in your project:

Note that localizable target files should only have target membership for one purpose, but your Localizable.strings should be for all purposes!
This is all for project configuration. Let's move on to writing scripts (for this I will use python):
#!/usr/bin/python import sys supportedLanguages = ["en","pl"] commonPath = ".lproj/Localizable.strings" keys = ["AppName"] class CopyLocalizable(): target = "" def __init__(self,arg): self.target = arg self.perform() def perform(self): for lang in supportedLanguages: pathToLocalizable = lang+commonPath textToFile = "" with open(pathToLocalizable,"r") as languageFile: for line in languageFile.readlines(): for key in keys: if key in line: textToFile += self.foundAndReplace(key,lang) else: textToFile += line self.saveInFile(pathToLocalizable,textToFile) def foundAndReplace(self,key,lang): pathToTargetFile = "Localizable/"+lang+".lproj/"+self.target+".strings" with open(pathToTargetFile,"r") as targetFile: for targetLine in targetFile.readlines(): if key in targetLine: return targetLine def saveInFile(self,file,stringToSave): with open(file,"w+") as languageFile: languageFile.write(stringToSave)
You can optimize it yourself. This is a simpler script. I can think of doing the job.
And at the end, let it automate it a bit: - Go to your goal - add a new build phase - Add a new script:
export PATH="/usr/local/bin:$PATH" cd SO45279964/ python localize.py target[x]
and watch the magic happen;)
http://www.giphy.com/gifs/26n6NKgiwYvuQk7WU
Here you can find an example project that I created to run this example: https://github.com/JakubMazur/SO45279964