我在Swift中使用新的统一日志API.
所以我创建了一个记录器并使用它如下:
let testLogger = OSLog(subsystem: "my.subsystem", category: "test")
os_log("just a test: %@", log: testLogger, type: .error, "error")
Run Code Online (Sandbox Code Playgroud)
如果iOS设备与Mac断开连接,如何检索记录的消息?
我知道新的控制台应用程序会显示设备连接到Mac时记录的消息.但是,我想检索设备与计算机断开连接时记录的消息.我怎样才能做到这一点?
谢谢.
I have an iPhone 8, and I'm trying to trigger a sysdiagnose with iOS 14.4 and up. You'd think that this is well-documented, and it is, but I still can't get it to work.
Here's what I've tried:
If you go to the Profiles and logs page here and filter by iOS: https://developer.apple.com/bug-reporting/profiles-and-logs/?platform=ios
There is documentation labelled "Sysdiagnose" which takes you here: https://download.developer.apple.com/iOS/iOS_Logs/sysdiagnose_Logging_Instructions.pdf
The instructions are pretty straightforward.
Hold the two volume buttons and the side button for 1-1.5 seconds. …