Skip to content

Commit bf60947

Browse files
authored
Sets default paths on Linux (#1429)
1 parent f252d56 commit bf60947

File tree

2 files changed

+8
-5
lines changed

2 files changed

+8
-5
lines changed

main/src/host-files/GameConfig.ts

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,12 @@ import type { ServerEvents } from '../server'
99

1010
const POSSIBLE_PATH =
1111
(process.platform === 'win32') ? [
12-
path.join(app.getPath('documents'), 'My Games', 'Path of Exile', 'production_Config.ini')
12+
path.join(app.getPath('documents'), 'My Games\\Path of Exile\\production_Config.ini')
1313
] : (process.platform === 'linux') ? [
14-
// TODO
14+
path.join(app.getPath('documents'), 'My Games/Path of Exile/production_Config.ini'),
15+
path.join(app.getPath('home'), '.local/share/Steam/steamapps/compatdata/238960/pfx/drive_c/users/steamuser/Documents/My Games/Path of Exile/production_Config.ini')
1516
] : (process.platform === 'darwin') ? [
16-
path.join(app.getPath('appData'), 'Path of Exile', 'Preferences', 'production_Config.ini')
17+
path.join(app.getPath('appData'), 'Path of Exile/Preferences/production_Config.ini')
1718
] : []
1819

1920
export class GameConfig {

main/src/host-files/GameLogWatcher.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import { promises as fs, watchFile, unwatchFile } from 'fs'
2+
import path from 'path'
23
import { app } from 'electron'
34
import { guessFileLocation } from './utils'
45
import { ServerEvents } from '../server'
@@ -9,9 +10,10 @@ const POSSIBLE_PATH =
910
'C:\\Program Files (x86)\\Grinding Gear Games\\Path of Exile\\logs\\Client.txt',
1011
'C:\\Program Files (x86)\\Steam\\steamapps\\common\\Path of Exile\\logs\\Client.txt'
1112
] : (process.platform === 'linux') ? [
12-
// TODO
13+
path.join(app.getPath('home'), '.wine/drive_c/Program Files (x86)/Grinding Gear Games/Path of Exile/logs/Client.txt'),
14+
path.join(app.getPath('home'), '.local/share/Steam/steamapps/common/Path of Exile/logs/Client.txt')
1315
] : (process.platform === 'darwin') ? [
14-
`${app.getPath('home')}/Library/Caches/com.GGG.PathOfExile/Logs/Client.txt`
16+
path.join(app.getPath('home'), 'Library/Caches/com.GGG.PathOfExile/Logs/Client.txt')
1517
] : []
1618

1719
export class GameLogWatcher {

0 commit comments

Comments
 (0)