utmctl: detect path if UTM.app was renamed

Fixes #7094
This commit is contained in:
osy
2025-04-07 12:42:03 -07:00
parent bf72a60e92
commit 39a68379b6
+1 -1
View File
@@ -93,7 +93,7 @@ extension UTMAPICommand {
private var utmAppUrl: URL {
if let executableURL = Bundle.main.executableURL?.resolvingSymlinksInPath() {
let utmURL = executableURL.deletingLastPathComponent().deletingLastPathComponent().deletingLastPathComponent()
if utmURL.lastPathComponent == "UTM.app" {
if utmURL.pathExtension == "app" {
return utmURL
}
}