Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-26368

Technical Version / Marketing Version Not Updating

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Minor Minor
    • xcode-plugin
    • Jenkins v1.585, Xcode Plugin v1.4.7

      I updated my build server to Yosemite so that I could start building iOS 8 projects. At that time my builds stopped replacing / updating the technical & marketing values within the projects plist file.

      When I look at the log file (see attached) I see that it appears to be setting the information correctly, but at the bottom you can see that it's not actually using that information.

      I've made sure that the plist file is being referenced correctly in all locations and I'm not using any kind of relative path such as ${src} for it's file path.

      Build version 6A2008a
      Fetching marketing version number (CFBundleShortVersionString) from project.
      [Project] $ /usr/bin/agvtool mvers -terse1
      No marketing version found (CFBundleShortVersionString).
      Marketing version (CFBundleShortVersionString) found in project configuration: .
      Fetching technical version number (CFBundleVersion) from project.
      [Project] $ /usr/bin/agvtool vers -terse
      No marketing version found (CFBundleVersion)
      Technical version (CFBundleVersion) found in project configuration: .
      Updating marketing version (CFBundleShortVersionString) to: 0.1.13
      [Project] $ /usr/bin/agvtool new-marketing-version 0.1.13
      Setting CFBundleShortVersionString of project Project to: 
          0.1.13.
      
      Updating CFBundleShortVersionString in Info.plist(s)...
      
      Cannot find "Project.xcodeproj/../				<key>INFOPLIST_FILE</key>"
      Updating technical version (CFBundleVersion) to: 0.1.13.216
      [Project] $ /usr/bin/agvtool new-version -all 0.1.13.216
      Setting version of project Project to: 
          0.1.13.216.
      
      Also setting CFBundleVersion key (assuming it exists)
      
      Updating CFBundleVersion in Info.plist(s)...
      
      Cannot find "Project.xcodeproj/../				<key>INFOPLIST_FILE</key>"
      
      
      Marketing version (CFBundleShortVersionString) used by Jenkins to produce the IPA: 0.1.13
      Technical version (CFBundleVersion) used by Jenkins to produce the IPA: 0.1.13.216
      
      ** BUILD SUCCEEDED **
      
      Cleaning up previously generated .ipa files
      Cleaning up previously generated .dSYM.zip files
      Packaging IPA
      [Project] $ /usr/libexec/PlistBuddy -c "Print :CFBundleVersion" "/Users/userXXX/.jenkins/workspace/ProjectXXX/build/Project.app/Info.plist"
      [Project] $ /usr/libexec/PlistBuddy -c "Print :CFBundleShortVersionString" "/Users/userXXX/.jenkins/workspace/ProjectXXX/build/Project.app/Info.plist"
      Packaging Project.app => /Users/userXXX/.jenkins/workspace/ProjectXXX/build/Project-0.1.13-0.1.13.4.ipa
      [Project] $ /usr/bin/xcrun -sdk iphoneos PackageApplication -v "/Users/userXXX/.jenkins/workspace/ProjectXXX/build/Project.app" -o "/Users/userXXX/.jenkins/workspace/ProjectXXX/build/Project-0.1.13-0.1.13.4.ipa"
      Packaging application: '/Users/userXXX/.jenkins/workspace/ProjectXXX/build/Project.app'
      Arguments: output=/Users/userXXX/.jenkins/workspace/ProjectXXX/build/Project-0.1.13-0.1.13.4.ipa  verbose=1  
      

          [JENKINS-26368] Technical Version / Marketing Version Not Updating

          lacostej added a comment -

          This looks a bit like this CocoaPods bug: https://github.com/CocoaPods/CocoaPods/issues/613
          in which the

          	
              pod install
          

          command changes the xcproject file format to one that agvtool isn't able to parse later on.

          See the error message:

          	
          Cannot find "Project.xcodeproj/../				<key>INFOPLIST_FILE</key>"
          

          lacostej added a comment - This looks a bit like this CocoaPods bug: https://github.com/CocoaPods/CocoaPods/issues/613 in which the pod install command changes the xcproject file format to one that agvtool isn't able to parse later on. See the error message: Cannot find "Project.xcodeproj/../ <key>INFOPLIST_FILE</key>"

          lacostej added a comment -

          James, should I close this as a cocoapods issue. Have you tried to check the file format of the xcproject before and after you run your cocoapods command ?

          We could update the plugin to display a warning of the avgtool fails to do its intended operation. It looks like it does nothing special: https://github.com/jenkinsci/xcode-plugin/blob/master/src/main/java/au/com/rayh/XCodeBuilder.java#L343

          lacostej added a comment - James, should I close this as a cocoapods issue. Have you tried to check the file format of the xcproject before and after you run your cocoapods command ? We could update the plugin to display a warning of the avgtool fails to do its intended operation. It looks like it does nothing special: https://github.com/jenkinsci/xcode-plugin/blob/master/src/main/java/au/com/rayh/XCodeBuilder.java#L343

          James Parker added a comment - - edited

          I'm trying to figure this out, but still not sure how to fix the problem. I've tried updating cocoa pods and install xcodeproj, still not getting anywhere.

          James Parker added a comment - - edited I'm trying to figure this out, but still not sure how to fix the problem. I've tried updating cocoa pods and install xcodeproj, still not getting anywhere.

          Mark Edington added a comment -

          We were running into this at the end of last year. Installing xcproj (via homebrew) solved the problem for us. If you update the latest Cocoapods (0.36) supposedly that will fix the issue as well. See the comments here: https://github.com/CocoaPods/CocoaPods/issues/1723

          Mark Edington added a comment - We were running into this at the end of last year. Installing xcproj (via homebrew) solved the problem for us. If you update the latest Cocoapods (0.36) supposedly that will fix the issue as well. See the comments here: https://github.com/CocoaPods/CocoaPods/issues/1723

            Unassigned Unassigned
            parkej60 James Parker
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated: