0

I installed the command line tools in xcode 7.3 and in the command line I used the following command to generate the strings file:

  ibtool --generate-strings-file testFile.strings MyController.xib

and also I tried to give the directory path for my xib:

  ibtool --generate-strings-file testFile.strings UI/Screens/My\ Card/MyController.xib

I also tried the command with sudo infront of it, suggested from this answer

None of them worked.

I got the error:

 <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>com.apple.ibtool.errors</key>
    <array>
        <dict>
            <key>description</key>
            <string>Interface Builder could not open the document MyController.xib" because it does not exist.</string>
        </dict>
    </array>
</dict>
</plist>
Community
  • 1
  • 1
Teja Nandamuri
  • 11,045
  • 6
  • 57
  • 109

1 Answers1

0

I used the wrong location of the xib. I enetered the location of xib by seeing its heirarchy in the project navigatior in xcode. BUt the correct path can be found at File Inspector tab under Source Control option.

  1. Select the xib file

  2. Go to File Inspector in the Utilities section.

  3. Look at the Location path under source control option.It will be something like:

      /Users/VenkataManiteja/Desktop/iOS/MyProject/src/MyController.xib
    

and I changed the command to

   ibtool --generate-strings-file testFile.strings src/MyController.xib

and it worked.

Teja Nandamuri
  • 11,045
  • 6
  • 57
  • 109