From ac654ff346475e9b0f7e8bad065ff809144bd38b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=8E=E9=80=9A=E6=B4=B2?= Date: Wed, 8 Nov 2023 10:42:13 +0800 Subject: [PATCH] Host (macOS): update the latest models --- CHANGELOG.md | 3 +++ src/detection/host/host_apple.c | 9 +++++++++ 2 files changed, 12 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index fe57fe7e8..bab497143 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,8 @@ # 2.2.3 +Features: +* Update the latest mac models (Host, macOS) + Bugfixes: * Fix local ips detection on Android. Regression from `2.0.0` (LocalIP, Android) * Fix terminal detection on NixOS (Terminal) diff --git a/src/detection/host/host_apple.c b/src/detection/host/host_apple.c index 1c5789c70..d56f125a6 100644 --- a/src/detection/host/host_apple.c +++ b/src/detection/host/host_apple.c @@ -108,6 +108,15 @@ static const char* getProductName(const FFstrbuf* hwModel) else if(ffStrbufStartsWithS(hwModel, "Mac")) { const char* version = hwModel->chars + strlen("Mac"); + if(ffStrEquals(version, "15,3")) return "MacBook Pro (14-inch, Nov 2023, Two Thunderbolt / USB 4 ports)"; + if(ffStrEquals(version, "15,4")) return "iMac (24-inch, 2023, Two Thunderbolt / USB 4 ports)"; + if(ffStrEquals(version, "15,5")) return "iMac (24-inch, 2023, Two Thunderbolt / USB 4 ports, Two USB 3 ports)"; + if(ffStrEquals(version, "15,6") || + ffStrEquals(version, "15,8") || + ffStrEquals(version, "15,10")) return "MacBook Pro (14-inch, Nov 2023, Three Thunderbolt 4 ports)"; + if(ffStrEquals(version, "15,7") || + ffStrEquals(version, "15,9") || + ffStrEquals(version, "15,11")) return "MacBook Pro (16-inch, Nov 2023, Three Thunderbolt 4 ports)"; if(ffStrEquals(version, "14,15")) return "MacBook Air (15-inch, M2, 2023)"; if(ffStrEquals(version, "14,14")) return "Mac Studio (M2 Ultra, 2023, Two Thunderbolt 4 front ports)"; if(ffStrEquals(version, "14,13")) return "Mac Studio (M2 Max, 2023, Two USB-C front ports)";