mirror of
https://github.com/XcodesOrg/XcodesApp.git
synced 2026-02-02 11:33:02 +01:00
We were appending a version without appending a corresponding AvailableXcode, and these two arrays were being zipped later so they wouldn't line up. This change simplifies this method a bit by working on only a single array, and then also moves that appending to the end after the array of Xcodes is created.
37 lines
1.0 KiB
Swift
37 lines
1.0 KiB
Swift
import Foundation
|
|
import Version
|
|
import struct XCModel.SDKs
|
|
import struct XCModel.Compilers
|
|
|
|
/// A version of Xcode that's available for installation
|
|
public struct AvailableXcode: Codable {
|
|
public var version: Version
|
|
public let url: URL
|
|
public let filename: String
|
|
public let releaseDate: Date?
|
|
public let requiredMacOSVersion: String?
|
|
public let releaseNotesURL: URL?
|
|
public let sdks: SDKs?
|
|
public let compilers: Compilers?
|
|
|
|
public init(
|
|
version: Version,
|
|
url: URL,
|
|
filename: String,
|
|
releaseDate: Date?,
|
|
requiredMacOSVersion: String? = nil,
|
|
releaseNotesURL: URL? = nil,
|
|
sdks: SDKs? = nil,
|
|
compilers: Compilers? = nil
|
|
) {
|
|
self.version = version
|
|
self.url = url
|
|
self.filename = filename
|
|
self.releaseDate = releaseDate
|
|
self.requiredMacOSVersion = requiredMacOSVersion
|
|
self.releaseNotesURL = releaseNotesURL
|
|
self.sdks = sdks
|
|
self.compilers = compilers
|
|
}
|
|
}
|