only latest.log, better notification animation, better playtime updates
This commit is contained in:
parent
53a02cc7da
commit
e082fedf19
4 changed files with 88 additions and 27 deletions
|
|
@ -274,12 +274,12 @@ ipcMain.handle('shell:showItemInFolder', (e, p) => {
|
|||
})
|
||||
|
||||
ipcMain.handle('games:getLogs', (e, id) => {
|
||||
const dir = path.join(DIRS.DATA, 'logs')
|
||||
let files = []
|
||||
const file = require('./runner').latestLogPath(id)
|
||||
try {
|
||||
files = require('fs').readdirSync(dir).filter(f => f.startsWith(id + '-')).sort()
|
||||
fs.accessSync(file)
|
||||
return [file]
|
||||
} catch {}
|
||||
return files.map(f => path.join(dir, f))
|
||||
return []
|
||||
})
|
||||
|
||||
ipcMain.handle('games:kill', (e, id) => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue