Upon updating/bumping up the version and the build # in Xcode version 9.1, I saw the following upon doing git diff
diff --git a/star.xcodeproj/project.pbxproj b/star.xcodeproj/project.pbxproj index c4601526..8fa3c762 100644 --- a/star.xcodeproj/project.pbxproj +++ b/star.xcodeproj/project.pbxproj @@ -767,7 +767,7 @@ - F4487BE11FB28C400079BAAD /* BuildFile in Sources */ = {isa = PBXBuildFile; }; + F4487BE11FB28C400079BAAD /* (null) in Sources */ = {isa = PBXBuildFile; }; @@ -5625,7 +5625,7 @@ isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( - F4487BE11FB28C400079BAAD /* BuildFile in Sources */, + F4487BE11FB28C400079BAAD /* (null) in Sources */,); <key>CFBundlePackageType</key> <string>APPL</string> <key>CFBundleShortVersionString</key> - <string>2.11.4</string> + <string>2.11.5</string> <key>CFBundleSignature</key> <string>????</string> <key>CFBundleURLTypes</key> @@ -39,7 +39,7 @@ </dict> </array> <key>CFBundleVersion</key> - <string>02110400</string> + <string>02110500</string> <key>FacebookAppID</key> <string>70858204300</string> <key>FacebookBetaAppID</key>
All I did was bump up the version of the project. But upon doing a git status and a git diff, I see some null references in the .pbxproj file. Has anybody else seen this. As a side-note we also use Cocoapods in our project.
pbxproj contains all of the metadata about your project that Xcode uses to build it; the settings, the file references, configuration, targeted platforms, etc... I.e. it is a critically important.
A PBXBuildFile is a file in a target. It wraps a PBXFileReference and adds certain attributes like per-file compiler flags. If a file is added to a target, it will be listed in both sections. If a file is in more than one target, it will have more than one PBXBuildFile in the build files section.
Remove all occurrences of (null) in Sources
lines in your project.pbxproj
:
sed -i '' '/(null) in Sources /d' YOURPROJECT.xcodeproj/project.pbxproj
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With