Storyboard-Strings-Extraction icon indicating copy to clipboard operation
Storyboard-Strings-Extraction copied to clipboard

Does this work?

Open jonnyijapan opened this issue 11 years ago • 10 comments

I'm sorry I just can'T get this to work. Using Xcode 6, iOS8.

I tried it out like this: I have base localization already enabled for my Main_iPhone.storyboard. I added a new label to one of the view controllers. THen ran this script. Nothing happened... Nothing was added. The id of the label is not in any of the strings files.

jonnyijapan avatar Sep 22 '14 11:09 jonnyijapan

I'm using Xcode 5 iOS7 and am having issues too. The script created .strings files in my Base.lproj folder, but not in the language specific folders like en.lproj etc...

5ke avatar Sep 25 '14 09:09 5ke

Thanks a lot for your posts. I’m a very sorry but I am not using this script myself in any of my projects and I currently don’t have time to look into this more closely.

ole avatar Oct 01 '14 15:10 ole

Ok then you maybe you should add something like "unsupported" etc in readme to save people some time :-)

jonnyijapan avatar Oct 03 '14 01:10 jonnyijapan

I have a Base.lproj, en.lproj and ja.lproj. In the Base.lproj I have a Main.storyboard and a LaunchScreen.xib. So string are extracted and put into a new Main.strings file under the Base.lproj folder – but this file is not added to my project. I have to add it manually after running the script for the first time. But I also noticed that the ja.lproj/Main.strings is not updated – seems this script only supports the Main.storyboard? as no LaunchScreen.strings are not updated either.

MKGitHub avatar Oct 20 '14 15:10 MKGitHub

Made it work at least in my environment. Did a fork + PR.

nbonamy avatar Nov 11 '14 20:11 nbonamy

Works well here with the latest version of Xcode and the recent PR that was made. Would be cool to get rid of realpath though!

IMO Feel free to close.

allaire avatar Jan 02 '15 04:01 allaire

FYI: I just tried with Xcode 6.3.2 in a project that already had Base, English and German localizations. After adding the script as a build task, all my localized .strings files were empty (existing translations deleted). Of course I'm using git, so no harm done ;-)

audiocommander avatar Jun 11 '15 23:06 audiocommander

@audiocommander same here.

A1iAshoor avatar Sep 19 '15 03:09 A1iAshoor

If this doesn't work for you, you might want to checkout BartyCrouch, a command line tool written in Swift that does something fairly similar to this script. I've written it since there didn't seem to be a maintained solution right now (as it seems this repo isn't maintained anymore). I hope this helps.

Jeehut avatar Feb 15 '16 22:02 Jeehut

@Dschee Cool, thanks for the pointer.

ole avatar Feb 16 '16 10:02 ole