Fix Windows mpv logging and add log export (#88)

This commit is contained in:
2026-05-26 00:31:38 -07:00
committed by GitHub
parent 43ebc7d371
commit 11c196821d
150 changed files with 2748 additions and 582 deletions
+4 -3
View File
@@ -139,9 +139,10 @@ export async function updateAppImageFromRelease(options: {
};
}
const tempPath = path.join(
path.dirname(options.appImagePath),
`.${path.basename(options.appImagePath)}.update`,
const appImagePathApi = options.appImagePath.startsWith('/') ? path.posix : path;
const tempPath = appImagePathApi.join(
appImagePathApi.dirname(options.appImagePath),
`.${appImagePathApi.basename(options.appImagePath)}.update`,
);
try {
await fsDeps.writeFile(tempPath, data);
@@ -63,7 +63,7 @@ test('buildProtectedSupportAssetsCommand cleans up temporary extraction director
test('updateSupportAssetsFromRelease updates only the Linux rofi theme', async () => {
const xdgDataHome = fs.mkdtempSync(path.join(os.tmpdir(), 'subminer-xdg-data-'));
const dataDir = path.join(xdgDataHome, 'SubMiner');
const dataDir = path.posix.join(xdgDataHome, 'SubMiner');
fs.mkdirSync(path.join(dataDir, 'themes'), { recursive: true });
fs.mkdirSync(path.join(dataDir, 'plugin/subminer'), { recursive: true });
fs.writeFileSync(path.join(dataDir, 'themes/subminer.rasi'), 'old theme\n');
+6 -2
View File
@@ -30,8 +30,12 @@ export function detectSupportAssetDataDirs(options: {
xdgDataHome?: string;
}): string[] {
if (options.platform === 'linux') {
const xdgDataHome = options.xdgDataHome || path.join(options.homeDir, '.local/share');
return [path.join(xdgDataHome, 'SubMiner'), '/usr/local/share/SubMiner', '/usr/share/SubMiner'];
const xdgDataHome = options.xdgDataHome || path.posix.join(options.homeDir, '.local/share');
return [
path.posix.join(xdgDataHome, 'SubMiner'),
'/usr/local/share/SubMiner',
'/usr/share/SubMiner',
];
}
return [];
}