How to use iOS 10.3 devices with Xcode 8.2.1

You can avoid both the update to Xcode 8.3 (which works only with macOS Sierra) and the Dropbox download from a random link on GitHub, as suggested in other answers. To work with iOS 10.3 in Xcode 8.2.1, follow these steps: Exit Xcode 8.2.1 Download Xcode8.3.3.xip from Apple (https://developer.apple.com/services-account/download?path=/Developer_Tools/Xcode_8.3.3/Xcode8.3.3.xip) (requires sign-in) Unzip ~/Downloads/Xcode8.3.3.xip (in Finder, … Read more

Is there a writeToFile equivalent for Swift 3’s ‘Data’ type?

Use write(to: fileURL). For example: let fileURL = try! FileManager.default .url(for: .documentDirectory, in: .userDomainMask, appropriateFor: nil, create: false) .appendingPathComponent(“test.jpg”) do { try jpegData.write(to: fileURL, options: .atomic) } catch { print(error) } Or, if you really are stuck with a path, convert that to a URL: do { try data.write(to: URL(fileURLWithPath: path), options: .atomic) } catch … Read more

“End-of-central-directory signature not found.” when installing Xcode 8 beta xip file

The .xip file format contains an archive (xar containing a gzip archive and metadata) and a signature of the archive. The signature is important, since previously Xcode downloads have been altered (eg. XcodeGhost) to inject malicious code into apps. Therefore, approaches like skipping the verification (xattr -d com.apple.quarantine Xcode_8_beta.xip) seems irresponsible. I strongly encourage you … Read more

Xcode 8 – Provisioning Profile vs. Provisioning Profile (Deprecated)

Update 2017/02/13 User interface for managing signing certificates and provisioning profiles has been changed at Xcode 8.3 beta 2. Changed the user interface for managing signing certificates and provisioning profiles. Certificates are managed from the Accounts preferences pane by selecting a team and clicking Manage Certificates. Automatically managing signing is recommended, however if your app … Read more

preferredStatusBarStyle removed in Swift 3?

In iOS 10, preferredStatusBarStyle is a property, not a method. So instead of overriding it with a func declaration as you’ve done, you override the getter with a var declaration: override var preferredStatusBarStyle: UIStatusBarStyle { return .lightContent } The Swift compiler’s error message here could probably be better — since it seems to know your … Read more