feat: add Finder, ranking reset, and quit actions

This commit is contained in:
2026-10-13 17:38:29 +02:00
parent 7cfd8096a4
commit 400917de3b
7 changed files with 90 additions and 4 deletions
+13
View File
@@ -18,4 +18,17 @@ enum AppLauncher {
}
}
}
static func quit(_ url: URL) throws {
let path = url.standardizedFileURL.resolvingSymlinksInPath().path
for application in NSWorkspace.shared.runningApplications {
guard application.bundleURL?.standardizedFileURL.resolvingSymlinksInPath().path == path,
!application.isTerminated else { continue }
guard application.terminate() else {
throw NSError(domain: "Conjure", code: 1, userInfo: [
NSLocalizedDescriptionKey: "The application refused the quit request. Save your work and quit it manually."
])
}
}
}
}