KeyHandler // Change the path for dumpDOT.
This commit is contained in:
parent
cd1cffd22e
commit
c9d7409cc0
|
@ -107,11 +107,9 @@ public class KeyHandler {
|
||||||
// 在偵錯模式開啟時,將 GraphViz 資料寫入至指定位置。
|
// 在偵錯模式開啟時,將 GraphViz 資料寫入至指定位置。
|
||||||
if mgrPrefs.isDebugModeEnabled {
|
if mgrPrefs.isDebugModeEnabled {
|
||||||
let result = compositor.dumpDOT
|
let result = compositor.dumpDOT
|
||||||
|
let appSupportPath = FileManager.default.urls(for: .cachesDirectory, in: .userDomainMask)[0].path.appending("vChewing-visualization.dot")
|
||||||
do {
|
do {
|
||||||
try result.write(
|
try result.write(toFile: appSupportPath, atomically: true, encoding: .utf8)
|
||||||
toFile: "/private/var/tmp/vChewing-visualization.dot",
|
|
||||||
atomically: true, encoding: .utf8
|
|
||||||
)
|
|
||||||
} catch {
|
} catch {
|
||||||
IME.prtDebugIntel("Failed from writing dumpDOT results.")
|
IME.prtDebugIntel("Failed from writing dumpDOT results.")
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue