Skip to content

Commit 472e36e

Browse files
committed
adjust names
1 parent bfb8c2c commit 472e36e

2 files changed

Lines changed: 12 additions & 3 deletions

File tree

Xcodes/Frontend/InfoPane/PlatformsView.swift

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -43,10 +43,10 @@ struct PlatformsView: View {
4343
} label: {
4444
switch selectedRuntimeArchitecture {
4545
case .arm64:
46-
Label(selectedRuntimeArchitecture.rawValue, systemImage: "m4.button.horizontal")
46+
Label(selectedRuntimeArchitecture.displayString, systemImage: "m4.button.horizontal")
4747
.labelStyle(.trailingIcon)
4848
case .x86_64:
49-
Label(selectedRuntimeArchitecture.rawValue, systemImage: "cpu.fill")
49+
Label(selectedRuntimeArchitecture.displayString, systemImage: "cpu.fill")
5050
.labelStyle(.trailingIcon)
5151
}
5252
}
@@ -74,7 +74,7 @@ struct PlatformsView: View {
7474
Text("\(runtime.visibleIdentifier)")
7575
.font(.headline)
7676
ForEach(runtime.architectures ?? [], id: \.self) { architecture in
77-
TagView(text: architecture.rawValue)
77+
TagView(text: architecture.displayString)
7878
}
7979
pathIfAvailable(xcode: xcode, runtime: runtime)
8080

Xcodes/XcodesKit/Sources/XcodesKit/Models/XcodeReleases/Architecture.swift

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,15 @@ public enum Architecture: String, Codable, Equatable, Hashable, Identifiable {
1515
case arm64 = "arm64"
1616
/// The X86\_64 architecture (64-bit Intel)
1717
case x86_64 = "x86_64"
18+
19+
public var displayString: String {
20+
switch self {
21+
case .arm64:
22+
return "Apple Silicon"
23+
case .x86_64:
24+
return "Intel"
25+
}
26+
}
1827
}
1928

2029
extension Array where Element == Architecture {

0 commit comments

Comments
 (0)