fix: debug log写入应用安装目录而非桌面
This commit is contained in:
1 parent
9a366636f2
commit
cd7a9129ec
1 file changed
+2
-2
+2
-2
@@ -32,8 +32,8 @@ const os = require('os');
|
||||
}
|
||||
})();
|
||||
|
||||
// 日志文件 - 写到用户桌面方便查看
|
||||
const logFile = path.join(app.getPath('desktop'), 'author-debug.log');
|
||||
// 日志文件 - 写到应用安装根目录(exe 同级),方便查找
|
||||
const logFile = path.join(path.dirname(process.execPath), 'author-debug.log');
|
||||
function log(msg) {
|
||||
const line = `[${new Date().toISOString()}] ${msg}\n`;
|
||||
console.log(msg);
|
||||
|
||||
Reference in new issue
Block a user